diff options
Diffstat (limited to 'apps/files_versions')
-rw-r--r-- | apps/files_versions/tests/Command/CleanupTest.php | 2 | ||||
-rw-r--r-- | apps/files_versions/tests/Controller/PreviewControllerTest.php | 2 | ||||
-rw-r--r-- | apps/files_versions/tests/VersioningTest.php | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/apps/files_versions/tests/Command/CleanupTest.php b/apps/files_versions/tests/Command/CleanupTest.php index ace8e842e7b..69f822fcb84 100644 --- a/apps/files_versions/tests/Command/CleanupTest.php +++ b/apps/files_versions/tests/Command/CleanupTest.php @@ -48,7 +48,7 @@ class CleanupTest extends TestCase { /** @var \PHPUnit_Framework_MockObject_MockObject | IRootFolder */ protected $rootFolder; - public function setUp(): void { + protected function setUp(): void { parent::setUp(); $this->rootFolder = $this->getMockBuilder('OCP\Files\IRootFolder') diff --git a/apps/files_versions/tests/Controller/PreviewControllerTest.php b/apps/files_versions/tests/Controller/PreviewControllerTest.php index e771b82a42d..79afb8bd536 100644 --- a/apps/files_versions/tests/Controller/PreviewControllerTest.php +++ b/apps/files_versions/tests/Controller/PreviewControllerTest.php @@ -64,7 +64,7 @@ class PreviewControllerTest extends TestCase { /** @var IVersionManager|\PHPUnit_Framework_MockObject_MockObject */ private $versionManager; - public function setUp(): void { + protected function setUp(): void { parent::setUp(); $this->rootFolder = $this->createMock(IRootFolder::class); diff --git a/apps/files_versions/tests/VersioningTest.php b/apps/files_versions/tests/VersioningTest.php index d878ea9c3da..3f51f619629 100644 --- a/apps/files_versions/tests/VersioningTest.php +++ b/apps/files_versions/tests/VersioningTest.php @@ -620,10 +620,10 @@ class VersioningTest extends \Test\TestCase { $this->assertFalse(\OCA\Files_Versions\Storage::expire('/void/unexist.txt', self::TEST_VERSIONS_USER)); } - /** - * @expectedException \OC\User\NoUserException - */ + public function testExpireNonexistingUser() { + $this->expectException(\OC\User\NoUserException::class); + $this->logout(); // needed to have a FS setup (the background job does this) \OC_Util::setupFS(self::TEST_VERSIONS_USER); |