ruby 来自https://stackoverflow.com/questions/19731295/ruby-on-rails-rspec-controller-tests-are-failing

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了ruby 来自https://stackoverflow.com/questions/19731295/ruby-on-rails-rspec-controller-tests-are-failing相关的知识,希望对你有一定的参考价值。

respond_to do |format|
  if @restaurant.save
    format.html { redirect_to @restaurant, notice: 'Restaurant was successfully created.' }
    format.json { render action: 'show', status: :created, location: @restaurant }
  else
    puts @restaurant.errors.full_messages
    format.html { render action: 'new' }
    format.json { render json: @restaurant.errors, status: :unprocessable_entity }
  end
end

以上是关于ruby 来自https://stackoverflow.com/questions/19731295/ruby-on-rails-rspec-controller-tests-are-failing的主要内容,如果未能解决你的问题,请参考以下文章

ruby 优化和缩小您的GIT存储库(Ruby脚本)。来自Jeff Smith @ rallydev.com。

使用来自 GitLab 的私有 gem 构建一个 Ruby 项目

ruby 来自Denys的数字任务

在 Ruby 中解析来自 Eventbrite API 的 JSON 响应

ruby 来自https://stackoverflow.com/questions/2505067/class-self-idiom-in-ruby

ruby 来自http://culttt.com/2015/07/08/working-with-mixins-in-ruby/