diff options
Diffstat (limited to 't/app')
-rw-r--r-- | t/app/controller/alert.t | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/t/app/controller/alert.t b/t/app/controller/alert.t index 9189f5e97..5bf2af428 100644 --- a/t/app/controller/alert.t +++ b/t/app/controller/alert.t @@ -1,10 +1,13 @@ use strict; use warnings; use Test::More; +use LWP::Protocol::PSGI; use FixMyStreet::TestMech; my $mech = FixMyStreet::TestMech->new; +use t::Nominatim; + # check that we can get the page $mech->get_ok('/alert'); $mech->title_like(qr/^Local RSS feeds and email alerts/); @@ -38,8 +41,11 @@ FixMyStreet::override_config { $mech->content_contains('council:2651:City_of_Edinburgh'); $mech->content_contains('ward:2651:20728:City_of_Edinburgh:City_Centre'); - $mech->get_ok('/alert/list?pc=High Street'); - $mech->content_contains('We found more than one match for that location'); + subtest "Test Nominatim lookup" => sub { + LWP::Protocol::PSGI->register(t::Nominatim->run_if_script, host => 'nominatim.openstreetmap.org'); + $mech->get_ok('/alert/list?pc=High Street'); + $mech->content_contains('We found more than one match for that location'); + }; $mech->get_ok('/alert/list?pc='); $mech->content_contains('To find out what local alerts we have for you'); |