summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/files_sharing/tests/etagpropagation.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/files_sharing/tests/etagpropagation.php b/apps/files_sharing/tests/etagpropagation.php
index 2f3604e63cd..e7d5bb46258 100644
--- a/apps/files_sharing/tests/etagpropagation.php
+++ b/apps/files_sharing/tests/etagpropagation.php
@@ -192,7 +192,8 @@ class EtagPropagation extends PropagationTestCase {
public function testOwnerWritesToSingleFileShare() {
$this->loginAsUser(self::TEST_FILES_SHARING_API_USER1);
Filesystem::file_put_contents('/foo.txt', 'longer_bar');
- Filesystem::touch('/foo.txt', time() - 1);
+ $t = (int)Filesystem::filemtime('/foo.txt') - 1;
+ Filesystem::touch('/foo.txt', $t);
$this->assertEtagsNotChanged([self::TEST_FILES_SHARING_API_USER4, self::TEST_FILES_SHARING_API_USER3]);
$this->assertEtagsChanged([self::TEST_FILES_SHARING_API_USER1, self::TEST_FILES_SHARING_API_USER2]);