From 0c522aa040150dec776adbf8fc3fd60e61cb26d8 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Wed, 7 Jun 2017 11:24:00 +0200 Subject: [PATCH] Fix unit test Signed-off-by: Joas Schilling --- apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php b/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php index 739c8f62540..885f3c23c24 100644 --- a/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php +++ b/apps/dav/tests/unit/Connector/Sabre/FilesPluginTest.php @@ -341,11 +341,12 @@ class FilesPluginTest extends TestCase { $this->assertEquals('my_fingerprint', $propFind->get(self::DATA_FINGERPRINT_PROPERTYNAME)); } - /** - * @expectedException \Sabre\DAV\Exception\NotFound - */ public function testGetPropertiesWhenNoPermission() { - /** @var \OCA\DAV\Connector\Sabre\Directory | \PHPUnit_Framework_MockObject_MockObject $node */ + // No read permissions can be caused by files access control. + // But we still want to load the directory list, so this is okay for us. + // $this->expectException(\Sabre\DAV\Exception\NotFound::class); + + /** @var \OCA\DAV\Connector\Sabre\Directory|\PHPUnit_Framework_MockObject_MockObject $node */ $node = $this->getMockBuilder('\OCA\DAV\Connector\Sabre\Directory') ->disableOriginalConstructor() ->getMock(); -- 2.39.5