aboutsummaryrefslogtreecommitdiffstats
path: root/t/cobrand
diff options
context:
space:
mode:
authorMatthew Somerville <matthew-github@dracos.co.uk>2017-10-11 09:27:21 +0100
committerMatthew Somerville <matthew-github@dracos.co.uk>2017-10-11 09:27:21 +0100
commit2404b1954614d9cd93c44e42a13449b7a7efaae1 (patch)
treee98ff3989d37c120a7f1294d2bf914dc5e89cae3 /t/cobrand
parentdfe953289cc7e3c49ee547110b953b48c2948aab (diff)
parent5934b383754a2d298100a674a1ccefc2cb9e50af (diff)
Merge branch 'bit-of-yaml-tidying'
Diffstat (limited to 't/cobrand')
-rw-r--r--t/cobrand/fixamingata.t10
1 files changed, 5 insertions, 5 deletions
diff --git a/t/cobrand/fixamingata.t b/t/cobrand/fixamingata.t
index 1e6bd7e65..06b5830e3 100644
--- a/t/cobrand/fixamingata.t
+++ b/t/cobrand/fixamingata.t
@@ -1,13 +1,10 @@
-use Test::MockModule;
-
use mySociety::Locale;
use FixMyStreet::TestMech;
my $mech = FixMyStreet::TestMech->new;
-# Closest road reverse geocode mock
-my $resolver = Test::MockModule->new('LWP::Simple');
-$resolver->mock('get', sub($) { "<result></result>" });
+use t::Mock::Nominatim;
+LWP::Protocol::PSGI->register(t::Mock::Nominatim->to_psgi_app, host => 'nominatim.openstreetmap.org');
# Front page test
@@ -103,6 +100,9 @@ subtest "Test ajax decimal points" => sub {
$mech->get_ok('/ajax/lookup_location?term=12345');
# We want an actual decimal point in a JSON response...
$mech->content_contains('51.5');
+
+ $mech->get_ok('/ajax/lookup_location?term=high+street');
+ $mech->content_contains('Edinburgh');
};
};