Merge pull request #24574 from owncloud/stable9_24568

[Stable 9] Fix etag propegation test race condition
This commit is contained in:
Thomas Müller 2016-05-11 16:29:08 +02:00
commit 877a8f09b4
1 changed files with 2 additions and 1 deletions

View File

@ -126,7 +126,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]);