summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2015-05-20 13:52:08 +0200
committerVincent Petry <pvince81@owncloud.com>2015-05-20 13:52:08 +0200
commit7386257676cff4648f4e71d05cdabff75578e947 (patch)
treea7320e5eec4f943cbc03f97cf5b9d942a5ef672e /tests
parentf9784745776eda5caedbbc72cf516ae70bce6f6a (diff)
parent6d97dfb00c6bd660d9f8ac3a579f34d70fe87af1 (diff)
downloadnextcloud-server-7386257676cff4648f4e71d05cdabff75578e947.tar.gz
nextcloud-server-7386257676cff4648f4e71d05cdabff75578e947.zip
Merge pull request #16075 from owncloud/skeleton-copy-delay
wait with copying the skeleton untill login and setupfs are done
Diffstat (limited to 'tests')
-rw-r--r--tests/core/avatar/avatarcontrollertest.php6
-rw-r--r--tests/lib/testcase.php3
2 files changed, 4 insertions, 5 deletions
diff --git a/tests/core/avatar/avatarcontrollertest.php b/tests/core/avatar/avatarcontrollertest.php
index a5456eb6789..c58d7febc3f 100644
--- a/tests/core/avatar/avatarcontrollertest.php
+++ b/tests/core/avatar/avatarcontrollertest.php
@@ -88,11 +88,7 @@ class AvatarControllerTest extends \Test\TestCase {
$this->user = $this->getUniqueID('user');
OC::$server->getUserManager()->createUser($this->user, $this->user);
- \OC_Util::tearDownFS();
- \OC_User::setUserId('');
- Filesystem::tearDown();
- \OC_User::setUserId($this->user);
- \OC_Util::setupFS($this->user);
+ $this->loginAsUser($this->user);
// Create Cache dir
$view = new \OC\Files\View('/'.$this->user);
diff --git a/tests/lib/testcase.php b/tests/lib/testcase.php
index 76d5662da9d..c1ebfb025cf 100644
--- a/tests/lib/testcase.php
+++ b/tests/lib/testcase.php
@@ -174,6 +174,9 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase {
\OC\Files\Filesystem::tearDown();
\OC_User::setUserId($user);
\OC_Util::setupFS($user);
+ if (\OC_User::userExists($user)) {
+ \OC::$server->getUserFolder($user);
+ }
}
/**