From 61b9ca99915792a8a38011f708e8a6a6aabcda89 Mon Sep 17 00:00:00 2001 From: Matthew Somerville Date: Wed, 30 Oct 2024 16:24:39 +0000 Subject: [PATCH] [Surrey] Fix timed out age test. Report age uses current_timestamp, so fixed time does not matter, and 1st August is now over 90 days ago. --- t/cobrand/surrey.t | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/t/cobrand/surrey.t b/t/cobrand/surrey.t index b7780f0faea..7f6e35544b2 100644 --- a/t/cobrand/surrey.t +++ b/t/cobrand/surrey.t @@ -1,7 +1,6 @@ use FixMyStreet::TestMech; use FixMyStreet::Script::Reports; use FixMyStreet::Script::CSVExport; -use Test::MockTime 'set_fixed_time'; use File::Temp 'tempdir'; my $mech = FixMyStreet::TestMech->new; @@ -74,7 +73,6 @@ FixMyStreet::override_config { }; subtest 'Old reports are not shown on Surrey cobrand' => sub { - set_fixed_time('2024-09-20T12:00:00'); note 'A newly created report is shown on Surrey cobrand'; my $json = $mech->get_ok_json('/around?ajax=1&bbox=-0.45869262976076,51.28481314324,-0.42367370886232,51.302390882532'); is_deeply($json->{pins}, [ @@ -107,7 +105,7 @@ FixMyStreet::override_config { created => $dt, confirmed => $dt, }); - $json = $mech->get_ok_json('/around?ajax=1&bbox=-0.45869262976076,51.28481314324,-0.42367370886232,51.302390882532'); + $json = $mech->get_ok_json('/around?ajax=1&show_old_reports=1&bbox=-0.45869262976076,51.28481314324,-0.42367370886232,51.302390882532'); is_deeply($json->{pins}, [ [ "51.293415", "-0.441269", "yellow", $report->id, $report->title, "", 'false' ], ], 'Open311 report is initially in Surrey cobrand');