Correct Answer: validates :name, :presence => true
Explanation:
Note: This Question is unanswered, help us to find answer for this one
Ruby On Rails Skill Assessment
Your Skill Level: Poor
Retake Quizzes to improve it
More Ruby On Rails MCQ Questions
Which will interpolate within a string with the variable named 'monster'?
What is the output of the following ? s='foo' * 2 puts s
What ORM does Ruby on Rails use by default?
What is a typical file extension found in the app/controllers directory
Which of these is not a standard directory in a Rails application?
How would you render a view using a different layout in an ERB HTML view?
How do you add Ruby code inside Rails views and have its result outputted in the HTML file?
In ActiveRecord, what is the difference between the has_many and has_many :through associations?
You are using an existing database that has a table named coffee_orders. What would the ActiveRecord model be named in order to use that table?
When using an ActiveRecord model, which method will create the model instance in memory and save it to the database?