From 5b9106ae02b1c323f9743444881d7499c49a9853 Mon Sep 17 00:00:00 2001 From: Nyholm Date: Sun, 1 Nov 2020 18:27:51 +0100 Subject: [PATCH] [Finder] Force set access time in test --- Tests/Iterator/SortableIteratorTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Tests/Iterator/SortableIteratorTest.php b/Tests/Iterator/SortableIteratorTest.php index 5a47812b..add8e7df 100644 --- a/Tests/Iterator/SortableIteratorTest.php +++ b/Tests/Iterator/SortableIteratorTest.php @@ -35,9 +35,10 @@ public function testAccept($mode, $expected) case SortableIterator::SORT_BY_ACCESSED_TIME: touch(self::toAbsolute('.git')); sleep(1); - file_get_contents(self::toAbsolute('.bar')); + touch(self::toAbsolute('.bar'), time()); break; case SortableIterator::SORT_BY_CHANGED_TIME: + sleep(1); file_put_contents(self::toAbsolute('test.php'), 'foo'); sleep(1); file_put_contents(self::toAbsolute('test.py'), 'foo');