From 312df7e5b0224d9aff0767148879a854089e4ee1 Mon Sep 17 00:00:00 2001 From: Dave Arter Date: Mon, 30 Jan 2017 16:32:52 +0000 Subject: [Oxfordshire] Show simpler state list on inspect form Limits the state dropdown to those states which will be useful to OCC inspectors, as well as removing a few from the base template on the inspect form. Some slight template refactoring has made it easier for other cobrands to override the list, as well as sharing the template with the admin report_edit form to allow all states to be selected. Fixes mysociety/fixmystreetforcouncils#129 --- t/app/controller/report_inspect.t | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 't') diff --git a/t/app/controller/report_inspect.t b/t/app/controller/report_inspect.t index f092561db..9888fc0f4 100644 --- a/t/app/controller/report_inspect.t +++ b/t/app/controller/report_inspect.t @@ -57,9 +57,9 @@ FixMyStreet::override_config { }; subtest "test basic inspect submission" => sub { - $mech->submit_form_ok({ button => 'save', with_fields => { traffic_information => 'Yes', state => 'Planned', save_inspected => undef } }); + $mech->submit_form_ok({ button => 'save', with_fields => { traffic_information => 'Yes', state => 'Action Scheduled', save_inspected => undef } }); $report->discard_changes; - is $report->state, 'planned', 'report state changed'; + is $report->state, 'action scheduled', 'report state changed'; is $report->get_extra_metadata('traffic_information'), 'Yes', 'report data changed'; }; @@ -190,9 +190,9 @@ FixMyStreet::override_config { subtest "Oxfordshire-specific traffic management options are shown" => sub { $report->update({ state => 'confirmed' }); $mech->get_ok("/report/$report_id"); - $mech->submit_form_ok({ button => 'save', with_fields => { traffic_information => 'Signs and Cones', state => 'Planned', save_inspected => undef } }); + $mech->submit_form_ok({ button => 'save', with_fields => { traffic_information => 'Signs and Cones', state => 'Action Scheduled', save_inspected => undef } }); $report->discard_changes; - is $report->state, 'planned', 'report state changed'; + is $report->state, 'action scheduled', 'report state changed'; is $report->get_extra_metadata('traffic_information'), 'Signs and Cones', 'report data changed'; }; -- cgit v1.2.3