diff options
author | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-10-11 09:27:21 +0100 |
---|---|---|
committer | Matthew Somerville <matthew-github@dracos.co.uk> | 2017-10-11 09:27:21 +0100 |
commit | 2404b1954614d9cd93c44e42a13449b7a7efaae1 (patch) | |
tree | e98ff3989d37c120a7f1294d2bf914dc5e89cae3 /t/cobrand | |
parent | dfe953289cc7e3c49ee547110b953b48c2948aab (diff) | |
parent | 5934b383754a2d298100a674a1ccefc2cb9e50af (diff) |
Merge branch 'bit-of-yaml-tidying'
Diffstat (limited to 't/cobrand')
-rw-r--r-- | t/cobrand/fixamingata.t | 10 |
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'); }; }; |