X-Git-Url: https://git.openstreetmap.org/rails.git/blobdiff_plain/faf4c5aa7a3c75b89d32b7d2205d004f9aa99cb7..cf4cfc530ae54abee7b6a0dccbc9d4603ab35611:/test/controllers/issues_controller_test.rb diff --git a/test/controllers/issues_controller_test.rb b/test/controllers/issues_controller_test.rb index 980603e20..6eacac11d 100644 --- a/test/controllers/issues_controller_test.rb +++ b/test/controllers/issues_controller_test.rb @@ -20,7 +20,7 @@ class IssuesControllerTest < ActionController::TestCase assert_response :success assert_difference "Issue.count",1 do details = "Details of a report" - post :create, { :report => { :deatils => details}, + post :create, { :report => { :details => details}, :issue => { reportable_id: 1, reportable_type: "DiaryEntry", reported_user_id: 1} } end assert_response :redirect @@ -58,11 +58,11 @@ class IssuesControllerTest < ActionController::TestCase # Create Issue - get :new, {reportable_id: 1, reportable_type: "DiaryEntry", user: 1} + get :new, {reportable_id: 1, reportable_type: "DiaryEntry", reported_user_id: 1} assert_response :success assert_difference "Issue.count",1 do details = "Details of a report" - post :create, { :report => { :deatils => details}, + post :create, { :report => { :details => details}, :issue => { reportable_id: 1, reportable_type: "DiaryEntry", reported_user_id: 1} } end assert_response :redirect @@ -78,11 +78,11 @@ class IssuesControllerTest < ActionController::TestCase # Create Issue - get :new, {reportable_id: 1, reportable_type: "DiaryEntry", user: 1} + get :new, {reportable_id: 1, reportable_type: "DiaryEntry", reported_user_id: 1} assert_response :success assert_difference "Issue.count",1 do details = "Details of a report" - post :create, { :report => { :deatils => details}, + post :create, { :report => { :details => details}, :issue => { reportable_id: 1, reportable_type: "DiaryEntry", reported_user_id: 1} } end assert_response :redirect