diff options
author | Tom Needham <tom@owncloud.com> | 2015-01-03 15:58:36 +0000 |
---|---|---|
committer | Tom Needham <tom@owncloud.com> | 2015-01-03 15:58:36 +0000 |
commit | a20de1548d5eaa7298a18c223d53c6484d5f96ac (patch) | |
tree | 7e69f93e6fffe53f11a3a09f75087fe8ceb8f602 /apps/provisioning_api | |
parent | 5c0d7f2ee567524f0c6ab250742a51d57a91f65c (diff) | |
download | nextcloud-server-a20de1548d5eaa7298a18c223d53c6484d5f96ac.tar.gz nextcloud-server-a20de1548d5eaa7298a18c223d53c6484d5f96ac.zip |
Add proper group setup and teardown to all provisioning_api tests
Diffstat (limited to 'apps/provisioning_api')
-rw-r--r-- | apps/provisioning_api/tests/AppsTest.php | 7 | ||||
-rw-r--r-- | apps/provisioning_api/tests/groupsTest.php | 1 | ||||
-rw-r--r-- | apps/provisioning_api/tests/usersTest.php | 1 |
3 files changed, 9 insertions, 0 deletions
diff --git a/apps/provisioning_api/tests/AppsTest.php b/apps/provisioning_api/tests/AppsTest.php index 2a269450ccd..c68259d1756 100644 --- a/apps/provisioning_api/tests/AppsTest.php +++ b/apps/provisioning_api/tests/AppsTest.php @@ -27,6 +27,9 @@ class Test_Provisioning_Api_Apps extends PHPUnit_Framework_TestCase { private $users = array(); + function setUp() { + OC_Group::createGroup('admin'); + } /** * Generates a temp user * @param $num int number of users to generate @@ -98,4 +101,8 @@ class Test_Provisioning_Api_Apps extends PHPUnit_Framework_TestCase { } + function tearDown() { + OC_Group::deleteGroup('admin'); + } + } diff --git a/apps/provisioning_api/tests/groupsTest.php b/apps/provisioning_api/tests/groupsTest.php index fb1fe96e9c7..280e4792ff7 100644 --- a/apps/provisioning_api/tests/groupsTest.php +++ b/apps/provisioning_api/tests/groupsTest.php @@ -167,6 +167,7 @@ class Test_Provisioning_Api_Groups extends PHPUnit_Framework_TestCase { foreach($this->users as $user) { \OC_User::deleteUser($user); } + OC_Group::deleteGroup('admin'); } diff --git a/apps/provisioning_api/tests/usersTest.php b/apps/provisioning_api/tests/usersTest.php index 34df2769b21..381baa633e4 100644 --- a/apps/provisioning_api/tests/usersTest.php +++ b/apps/provisioning_api/tests/usersTest.php @@ -793,6 +793,7 @@ class Test_Provisioning_Api_Users extends PHPUnit_Framework_TestCase { foreach($this->users as $user) { \OC_User::deleteUser($user); } + OC_Group::deleteGroup('admin'); } } |