diff options
author | Christoph Wurst <christoph@winzerhof-wurst.at> | 2017-04-03 17:24:51 +0200 |
---|---|---|
committer | Christoph Wurst <christoph@winzerhof-wurst.at> | 2017-04-03 20:41:14 +0200 |
commit | e68f7771860952e9eeaab8d47bd168595a7c5731 (patch) | |
tree | 535b5569875cf6bde7115499a811fded33385198 /tests/unit/controller/PageControllerTest.php | |
parent | 186eb31de2b2d9d39edd99a585faeee44849a317 (diff) |
Use PSR-4 naming for classes
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'tests/unit/controller/PageControllerTest.php')
-rw-r--r-- | tests/unit/controller/PageControllerTest.php | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/tests/unit/controller/PageControllerTest.php b/tests/unit/controller/PageControllerTest.php deleted file mode 100644 index 548081da..00000000 --- a/tests/unit/controller/PageControllerTest.php +++ /dev/null @@ -1,48 +0,0 @@ -<?php -/** - * Nextcloud - contacts - * - * This file is licensed under the Affero General Public License version 3 or - * later. See the COPYING file. - * - * @author Hendrik Leppelsack <hendrik@leppelsack.de> - * @copyright Hendrik Leppelsack 2015 - */ - -namespace OCA\Contacts\Controller; - -use PHPUnit_Framework_TestCase; - -use OCP\AppFramework\Http\TemplateResponse; - - -class PageControllerTest extends PHPUnit_Framework_TestCase { - - private $controller; - private $userId = 'john'; - - public function setUp() { - $request = $this->getMockBuilder('OCP\IRequest')->getMock(); - - $this->controller = new PageController( - 'contacts', $request, $this->userId - ); - } - - - public function testIndex() { - $result = $this->controller->index(); - - $this->assertEquals(['user' => 'john'], $result->getParams()); - $this->assertEquals('main', $result->getTemplateName()); - $this->assertTrue($result instanceof TemplateResponse); - } - - - public function testEcho() { - $result = $this->controller->doEcho('hi'); - $this->assertEquals(['echo' => 'hi'], $result->getData()); - } - - -} |