aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--perllib/FixMyStreet/App/Controller/Report/Update.pm2
-rw-r--r--t/app/controller/report_updates.t12
2 files changed, 13 insertions, 1 deletions
diff --git a/perllib/FixMyStreet/App/Controller/Report/Update.pm b/perllib/FixMyStreet/App/Controller/Report/Update.pm
index 652694595..1ea0e88b4 100644
--- a/perllib/FixMyStreet/App/Controller/Report/Update.pm
+++ b/perllib/FixMyStreet/App/Controller/Report/Update.pm
@@ -181,7 +181,7 @@ sub check_for_errors : Private {
$error = 1 unless $c->user && $c->user->from_council && $c->user->from_council == $c->stash->{update}->problem->council;
my $state = $c->req->param('state');
- $error = 1 unless ( grep { $state eq $_ } ( qw/closed fixed investigating planned/, 'in progress', 'fixed', 'fixed - user', 'fixed - council' ) );
+ $error = 1 unless ( grep { $state eq $_ } ( qw/confirmed closed fixed investigating planned/, 'in progress', 'fixed', 'fixed - user', 'fixed - council' ) );
if ( $error ) {
$c->stash->{errors} ||= [];
diff --git a/t/app/controller/report_updates.t b/t/app/controller/report_updates.t
index 16165e8ae..72006dca8 100644
--- a/t/app/controller/report_updates.t
+++ b/t/app/controller/report_updates.t
@@ -510,6 +510,18 @@ for my $test (
},
state => 'fixed - council',
},
+ {
+ desc => 'from authority user marks report as confirmed',
+ fields => {
+ name => $user->name,
+ may_show_name => 1,
+ add_alert => 0,
+ photo => '',
+ update => 'Set state to investigating',
+ state => 'confirmed',
+ },
+ state => 'confirmed',
+ },
) {
subtest $test->{desc} => sub {
$report->comments->delete;