diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2016-12-01 18:23:54 +0000 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2016-12-16 10:15:00 +0000 |
commit | 020769f403ef4cf1880bd061b6db6b4f4028d3e4 (patch) | |
tree | 6db18df5d7e3a4743c34802bd441946187d7e19c /t/app/controller/report_updates.t | |
parent | b8aa0d6da9009dc3182093165df9b1a4c6d7d164 (diff) |
Return 400/500 for some client/server errors.
Diffstat (limited to 't/app/controller/report_updates.t')
-rw-r--r-- | t/app/controller/report_updates.t | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/t/app/controller/report_updates.t b/t/app/controller/report_updates.t index 5a88097fa..f7544f0a1 100644 --- a/t/app/controller/report_updates.t +++ b/t/app/controller/report_updates.t @@ -1829,7 +1829,8 @@ for my $test ( subtest 'check have to be logged in for creator fixed questionnaire' => sub { $mech->log_out_ok(); - $mech->get_ok( "/questionnaire/submit?problem=$report_id&reported=Yes" ); + $mech->get( "/questionnaire/submit?problem=$report_id&reported=Yes" ); + is $mech->res->code, 400, "got 400"; $mech->content_contains( "I'm afraid we couldn't locate your problem in the database." ) }; @@ -1838,7 +1839,8 @@ subtest 'check cannot answer other user\'s creator fixed questionnaire' => sub { $mech->log_out_ok(); $mech->log_in_ok( $user2->email ); - $mech->get_ok( "/questionnaire/submit?problem=$report_id&reported=Yes" ); + $mech->get( "/questionnaire/submit?problem=$report_id&reported=Yes" ); + is $mech->res->code, 400, "got 400"; $mech->content_contains( "I'm afraid we couldn't locate your problem in the database." ) }; |