##// END OF EJS Templates
Rails4: replace deprecated Relation#first with finder options at IssueCategoriesControllerTest...
Toshi MARUYAMA -
r12234:d9dc18011df3
parent child
Show More
@@ -66,7 +66,7 class IssueCategoriesControllerTest < ActionController::TestCase
66 assert_difference 'IssueCategory.count' do
66 assert_difference 'IssueCategory.count' do
67 xhr :post, :create, :project_id => '1', :issue_category => {:name => 'New category'}
67 xhr :post, :create, :project_id => '1', :issue_category => {:name => 'New category'}
68 end
68 end
69 category = IssueCategory.first(:order => 'id DESC')
69 category = IssueCategory.order('id DESC').first
70 assert_equal 'New category', category.name
70 assert_equal 'New category', category.name
71
71
72 assert_response :success
72 assert_response :success
General Comments 0
You need to be logged in to leave comments. Login now