aboutsummaryrefslogtreecommitdiffstats
path: root/t/app
diff options
context:
space:
mode:
Diffstat (limited to 't/app')
-rw-r--r--t/app/controller/around.t22
-rw-r--r--t/app/controller/index.t6
-rw-r--r--t/app/uri_for.t8
3 files changed, 3 insertions, 33 deletions
diff --git a/t/app/controller/around.t b/t/app/controller/around.t
index cb36833ad..ed29d438c 100644
--- a/t/app/controller/around.t
+++ b/t/app/controller/around.t
@@ -18,28 +18,6 @@ subtest "check that if no query we get sent back to the homepage" => sub {
is $mech->uri->path, '/', "redirected to '/'";
};
-# x,y requests were generated by the old map code. We keep the behavior for
-# historic links
-subtest "redirect x,y requests to lat/lon (301 - permanent)" => sub {
-
- FixMyStreet::override_config {
- MAPIT_URL => 'http://mapit.uk/',
- }, sub {
- $mech->get_ok('/around?x=3281&y=1113');
- };
-
- # did we redirect to lat,lon?
- is $mech->uri->path, '/around', "still on /around";
- is_deeply { $mech->uri->query_form },
- { lat => 51.499825, lon => -0.140137, zoom => 3 },
- "lat,lon correctly set";
-
- # was it a 301?
- is $mech->res->code, 200, "got 200 for final destination";
- is $mech->res->previous->code, 301, "got 301 for redirect";
-
-};
-
# test various locations on inital search box
foreach my $test (
{
diff --git a/t/app/controller/index.t b/t/app/controller/index.t
index 9be6dfa1e..bd268b3d7 100644
--- a/t/app/controller/index.t
+++ b/t/app/controller/index.t
@@ -29,15 +29,15 @@ subtest "does pc, (x,y), (e,n) or (lat,lon) go to /around" => sub {
},
{
in => { lat => 51.50100, lon => -0.14158 },
- out => { lat => 51.50100, lon => -0.14158, zoom => 3 },
+ out => { lat => 51.50100, lon => -0.14158 },
},
{
in => { x => 3281, y => 1113, },
- out => { lat => 51.499825, lon => -0.140137, zoom => 3 },
+ out => { lat => 51.499825, lon => -0.140137 },
},
{
in => { e => 1234, n => 4567 },
- out => { lat => 49.808509, lon => -7.544784, zoom => 3 },
+ out => { lat => 49.808509, lon => -7.544784 },
},
)
{
diff --git a/t/app/uri_for.t b/t/app/uri_for.t
index 7d9c8dc07..61713f8b7 100644
--- a/t/app/uri_for.t
+++ b/t/app/uri_for.t
@@ -13,7 +13,6 @@ use URI;
use_ok('FixMyStreet::App');
my $fms_c = ctx_request('http://www.fixmystreet.com/');
-my $fgm_c = ctx_request('http://www.fiksgatami.no/');
is(
$fms_c->uri_for('/bar/baz') . "",
@@ -33,11 +32,4 @@ is(
'URI with query'
);
-# fiksgatami
-is(
- $fgm_c->uri_for( '/foo', { lat => 1.23, } ) . "",
- 'http://www.fiksgatami.no/foo?lat=1.23&zoom=3',
- 'FiksGataMi url with lat not zoom'
-);
-
done_testing();