aboutsummaryrefslogtreecommitdiffstats
path: root/t/app/controller/report_new.t
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2012-07-06 12:10:46 +0100
committerMatthew Somerville <matthew@mysociety.org>2012-07-06 12:10:46 +0100
commit842ff2b00f4924f8580710c977ccce7bef33b0c2 (patch)
treee2ab4fda5a811b214fb4f501208f98f07a2c3c41 /t/app/controller/report_new.t
parentdeb369669b540f607e435390f4606b927569dded (diff)
Factor out the SQL restriction from site_restriction, as it's only used in one place.
Diffstat (limited to 't/app/controller/report_new.t')
-rw-r--r--t/app/controller/report_new.t8
1 files changed, 8 insertions, 0 deletions
diff --git a/t/app/controller/report_new.t b/t/app/controller/report_new.t
index 29fb650e5..2875af537 100644
--- a/t/app/controller/report_new.t
+++ b/t/app/controller/report_new.t
@@ -34,6 +34,9 @@ my %contact_params = (
note => 'Created for test',
);
# Let's make some contacts to send things to!
+FixMyStreet::App->model('DB::Contact')->search( {
+ email => { 'like', '%example.com' },
+} )->delete;
my $contact1 = FixMyStreet::App->model('DB::Contact')->find_or_create( {
%contact_params,
area_id => 2651, # Edinburgh
@@ -859,6 +862,11 @@ for my $test (
)
{
subtest $test->{desc} => sub {
+ if ( $test->{host} =~ /bromley/ && !FixMyStreet::Cobrand->exists('bromley') ) {
+ ok 1, 'Skipping Bromley tests without Bromley cobrand';
+ return;
+ }
+
$mech->host( $test->{host} );
$mech->log_out_ok;