Fix rubocop warnings

This commit is contained in:
Tom Hughes 2016-10-20 22:00:56 +01:00
parent 9d106676b8
commit e17b89e89f
17 changed files with 105 additions and 80 deletions

View file

@ -99,7 +99,7 @@ class OauthClientsControllerTest < ActionController::TestCase
}, { :user => user }
end
assert_response :redirect
assert_redirected_to oauth_client_path(:id => ClientApplication.find_by_name("Test Application").id)
assert_redirected_to oauth_client_path(:id => ClientApplication.find_by(:name => "Test Application").id)
end
def test_show

View file

@ -73,7 +73,7 @@ class RedactionsControllerTest < ActionController::TestCase
post :create, :redaction => { :title => "Foo", :description => "Description here." }
assert_response :redirect
assert_redirected_to(redaction_path(Redaction.find_by_title("Foo")))
assert_redirected_to(redaction_path(Redaction.find_by(:title => "Foo")))
end
def test_create_moderator_invalid