diff options
author | Thomas Citharel <tcit@tcit.fr> | 2016-07-31 20:18:35 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@statuscode.ch> | 2016-09-26 11:55:39 +0200 |
commit | 3921385ed3994c26674ec31606a41899fa8648ee (patch) | |
tree | b5ace47668519e029a342f26e936056d790836c5 /apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php | |
parent | ebf23778f5a71b421021165627738e6e7ed5216f (diff) | |
download | nextcloud-server-3921385ed3994c26674ec31606a41899fa8648ee.tar.gz nextcloud-server-3921385ed3994c26674ec31606a41899fa8648ee.zip |
fix things (indentation, tests, comments, backend custom implementation
Diffstat (limited to 'apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php')
-rw-r--r-- | apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php b/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php index b3ff36fc4ed..69de507dac5 100644 --- a/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php +++ b/apps/dav/tests/unit/CalDAV/Publishing/PublishingTest.php @@ -4,7 +4,6 @@ namespace OCA\DAV\Tests\unit\CalDAV\Publishing; use OCA\DAV\CalDAV\Calendar; use OCA\DAV\CalDAV\Publishing\PublishPlugin; -use OCA\DAV\Connector\Sabre\Auth; use OCP\IRequest; use OCP\IURLGenerator; use OCP\IConfig; @@ -30,16 +29,16 @@ class PluginTest extends TestCase { public function setUp() { parent::setUp(); - /** @var Auth | \PHPUnit_Framework_MockObject_MockObject $authBackend */ - $authBackend = $this->getMockBuilder('OCA\DAV\DAV\PublicAuth')->disableOriginalConstructor()->getMock(); - $authBackend->method('isDavAuthenticated')->willReturn(true); - - $this->config = $this->getMock('\OCP\IConfig'); + $this->config = $this->getMockBuilder('\OCP\IConfig')-> + disableOriginalConstructor()-> + getMock(); $this->config->expects($this->any())->method('getSystemValue') ->with($this->equalTo('secret')) ->willReturn('mysecret'); - $this->urlGenerator = $this->getMock('OCP\IURLGenerator'); + $this->urlGenerator = $this->getMockBuilder('OCP\IURLGenerator')-> + disableOriginalConstructor()-> + getMock(); /** @var IRequest $request */ $this->plugin = new PublishPlugin($this->config, $this->urlGenerator); @@ -48,8 +47,8 @@ class PluginTest extends TestCase { $this->server = new Server($root); /** @var SimpleCollection $node */ $this->book = $this->getMockBuilder('OCA\DAV\CalDAV\Calendar')-> - disableOriginalConstructor()-> - getMock(); + disableOriginalConstructor()-> + getMock(); $this->book->method('getName')->willReturn('cal1'); $root->addChild($this->book); $this->plugin->initialize($this->server); |