Commit ed4dc4db authored by Robin McCorkell's avatar Robin McCorkell
Browse files

Fix slash normalization error in AmazonS3Migration unit test

Since aa821ecc leading and trailing slashes are
trimmed in the file cache paths
parent d6b9b37d
......@@ -64,7 +64,7 @@ class AmazonS3Migration extends \Test\TestCase {
$oldCache = new \OC\Files\Cache\Cache($this->oldId);
// add file to old cache
$fileId = $oldCache->put('/', array('size' => 0, 'mtime' => time(), 'mimetype' => 'httpd/directory'));
$fileId = $oldCache->put('foobar', array('size' => 0, 'mtime' => time(), 'mimetype' => 'httpd/directory'));
try {
$this->instance = new \OC\Files\Storage\AmazonS3($this->params);
......@@ -80,7 +80,7 @@ class AmazonS3Migration extends \Test\TestCase {
list($storageId, $path) = \OC\Files\Cache\Cache::getById($fileId);
$this->assertSame($this->newId, $storageId);
$this->assertSame('/', $path);
$this->assertSame('foobar', $path);
}
public function testUpdateLegacyAndNewId () {
......@@ -127,4 +127,4 @@ class AmazonS3Migration extends \Test\TestCase {
);
$stmt->execute(array($id));
}
}
\ No newline at end of file
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment