diff --git a/bin/compress_archives/test_compress_archives.py b/bin/compress_archives/test_compress_archives.py index ecfe7838..83a0fdc1 100644 --- a/bin/compress_archives/test_compress_archives.py +++ b/bin/compress_archives/test_compress_archives.py @@ -75,7 +75,9 @@ class Main(unittest.TestCase): self.assertTrue((self.archive / "b.jsonl").is_file()) def test_keeps_a_file_copied_today_with_its_old_times_plain(self): - self.assertEqual(self.run_main(now=time.time()), (0, "Compressed 0 files.\n", "")) + now = time.time() + os.utime(self.archive / "a.jsonl", (now - 31 * DAY, now - 31 * DAY)) + self.assertEqual(self.run_main(now=now), (0, "Compressed 0 files.\n", "")) self.assertTrue((self.archive / "a.jsonl").is_file()) def test_measures_the_30_days_from_the_clock_by_default(self):