summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorLukas Reschke <lukas@owncloud.com>2014-09-19 13:02:22 +0200
committerLukas Reschke <lukas@owncloud.com>2014-09-19 13:02:22 +0200
commit079ad18bce537c1c831c4a635ac26fb2f28956fa (patch)
treeb7b2a89d61ce136b5965ce988b6f242c6c039533 /tests
parent437f8c3cd53aa324519fb34e1f4dbb3318d5970a (diff)
parent55d56f2f0fa880e7837e055a98a011587f24ab3d (diff)
downloadnextcloud-server-079ad18bce537c1c831c4a635ac26fb2f28956fa.tar.gz
nextcloud-server-079ad18bce537c1c831c4a635ac26fb2f28956fa.zip
Merge pull request #11142 from owncloud/fix-windows
Resolves cache tests failing if the directory length is longer than 64
Diffstat (limited to 'tests')
-rw-r--r--tests/lib/files/cache/cache.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/lib/files/cache/cache.php b/tests/lib/files/cache/cache.php
index 03fe4b26e7f..969740419c6 100644
--- a/tests/lib/files/cache/cache.php
+++ b/tests/lib/files/cache/cache.php
@@ -336,6 +336,10 @@ class Cache extends \PHPUnit_Framework_TestCase {
$storageId = $this->storage->getId();
$data = array('size' => 1000, 'mtime' => 20, 'mimetype' => 'foo/file');
$id = $this->cache->put('foo', $data);
+
+ if (strlen($storageId) > 64) {
+ $storageId = md5($storageId);
+ }
$this->assertEquals(array($storageId, 'foo'), \OC\Files\Cache\Cache::getById($id));
}