diff options
author | Bernhard Posselt <nukeawhale@gmail.com> | 2013-02-02 00:23:55 +0100 |
---|---|---|
committer | Bernhard Posselt <nukeawhale@gmail.com> | 2013-02-02 00:23:55 +0100 |
commit | d4064fe2c7c1b5a6eb89714503c0fe775729d8af (patch) | |
tree | 200945a7363b320d71934a41e3dafbdb8e534879 | |
parent | 703502d7c4d5f06a2d3425b7b7eef62c7fff9863 (diff) |
added annotations test
-rw-r--r-- | tests/controller/FolderControllerTest.php | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/tests/controller/FolderControllerTest.php b/tests/controller/FolderControllerTest.php index 684da0ba3..de05f8dee 100644 --- a/tests/controller/FolderControllerTest.php +++ b/tests/controller/FolderControllerTest.php @@ -26,12 +26,13 @@ namespace OCA\News\Controller; use \OCA\AppFramework\Http\Request; +use OCA\AppFramework\Utility\ControllerTestUtility; require_once(__DIR__ . "/../classloader.php"); -class FolderControllerTest extends \PHPUnit_Framework_TestCase { +class FolderControllerTest extends ControllerTestUtility { private $api; private $folderMapper; @@ -43,8 +44,7 @@ class FolderControllerTest extends \PHPUnit_Framework_TestCase { * Gets run before each test */ public function setUp(){ - $this->api = $this->getMock('\OCA\AppFramework\Core\API', - null, array('news')); + $this->api = $this->getAPIMock(); $this->folderMapper = $this->getMock('FolderMapper', array('getAll')); $this->request = new Request(); @@ -77,4 +77,12 @@ class FolderControllerTest extends \PHPUnit_Framework_TestCase { } + public function testGetAllAnnotations(){ + $methodName = 'getAll'; + $annotations = array('IsAdminExemption', 'IsSubAdminExemption'); + + $this->assertAnnotations($this->controller, $methodName, $annotations); + } + + }
\ No newline at end of file |