diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files/tests/command/deleteorphanedfilestest.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/files/tests/command/deleteorphanedfilestest.php b/apps/files/tests/command/deleteorphanedfilestest.php index 76fe9dbdfa0..3a1a541d8f1 100644 --- a/apps/files/tests/command/deleteorphanedfilestest.php +++ b/apps/files/tests/command/deleteorphanedfilestest.php @@ -22,6 +22,7 @@ namespace OCA\Files\Tests\Command; use OCA\Files\Command\DeleteOrphanedFiles; +use OCP\Files\StorageNotAvailableException; class DeleteOrphanedFilesTest extends \Test\TestCase { @@ -110,7 +111,11 @@ class DeleteOrphanedFilesTest extends \Test\TestCase { $this->assertCount(0, $this->getFile($fileInfo->getId()), 'Asserts that file gets cleaned up'); - $view->unlink('files/test'); + // since we deleted the storage it might throw a (valid) StorageNotAvailableException + try { + $view->unlink('files/test'); + } catch (StorageNotAvailableException $e) { + } } } |