From e973904765e4efb242d09d3d41d7f9eb0a294424 Mon Sep 17 00:00:00 2001 From: Matthew Somerville Date: Tue, 10 Jan 2017 14:58:59 +0000 Subject: Move staging flags to their own config variable. --- t/cobrand/bromley.t | 2 +- t/cobrand/zurich.t | 4 ++-- t/sendreport/open311.t | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 't') diff --git a/t/cobrand/bromley.t b/t/cobrand/bromley.t index 43d936684..a7cc563dc 100644 --- a/t/cobrand/bromley.t +++ b/t/cobrand/bromley.t @@ -55,7 +55,7 @@ subtest 'testing special Open311 behaviour', sub { $body->update( { send_method => 'Open311', endpoint => 'http://bromley.endpoint.example.com', jurisdiction => 'FMS', api_key => 'test' } ); my $test_data; FixMyStreet::override_config { - SEND_REPORTS_ON_STAGING => 1, + STAGING_FLAGS => { send_reports => 1 }, ALLOWED_COBRANDS => [ 'fixmystreet', 'bromley' ], }, sub { $test_data = FixMyStreet::DB->resultset('Problem')->send_reports(); diff --git a/t/cobrand/zurich.t b/t/cobrand/zurich.t index ddaae1f90..85cada27a 100644 --- a/t/cobrand/zurich.t +++ b/t/cobrand/zurich.t @@ -28,12 +28,12 @@ ok $sample_file->exists, "sample file $sample_file exists"; my $sample_photo = $sample_file->slurp_raw; # This is a helper method that will send the reports but with the config -# correctly set - notably SEND_REPORTS_ON_STAGING needs to be true, and +# correctly set - notably STAGING_FLAGS send_reports needs to be true, and # zurich must be allowed cobrand if we want to be able to call cobrand # methods on it. sub send_reports_for_zurich { FixMyStreet::override_config { - SEND_REPORTS_ON_STAGING => 1, + STAGING_FLAGS => { send_reports => 1 }, ALLOWED_COBRANDS => ['zurich'] }, sub { # Actually send the report diff --git a/t/sendreport/open311.t b/t/sendreport/open311.t index 636faba31..c40b64d12 100644 --- a/t/sendreport/open311.t +++ b/t/sendreport/open311.t @@ -26,7 +26,7 @@ subtest 'testing Open311 behaviour', sub { $body->update( { send_method => 'Open311', endpoint => 'http://endpoint.example.com', jurisdiction => 'FMS', api_key => 'test' } ); my $test_data; FixMyStreet::override_config { - SEND_REPORTS_ON_STAGING => 1, + STAGING_FLAGS => { send_reports => 1 }, ALLOWED_COBRANDS => [ 'fixmystreet' ], }, sub { $test_data = FixMyStreet::DB->resultset('Problem')->send_reports(); -- cgit v1.2.3