作者:gvd
项目:contacts-
public function tearDown()
{
unset($this->backend);
unset($this->ab);
Utils\Properties::purgeIndexes($this->contactIds);
parent::tearDown();
}
作者:0x17d
项目:cor
public static function tearDownAfterClass()
{
\OC_User::deleteUser(self::TEST_ENCRYPTION_MIGRATION_USER1);
\OC_User::deleteUser(self::TEST_ENCRYPTION_MIGRATION_USER2);
\OC_User::deleteUser(self::TEST_ENCRYPTION_MIGRATION_USER3);
parent::tearDownAfterClass();
}
作者:TechAre
项目:cor
public function setUp()
{
parent::setUp();
$this->session = $this->getMockBuilder('\\OCP\\ISession')->disableOriginalConstructor()->getMock();
$this->userSession = $this->getMockBuilder('\\OCP\\IUserSession')->disableOriginalConstructor()->getMock();
$this->auth = new \OCA\DAV\Connector\Sabre\Auth($this->session, $this->userSession);
}
作者:ris
项目:owncloud-cor
protected function setUp()
{
parent::setUp();
if (!function_exists('idn_to_ascii')) {
$this->markTestSkipped('The intl extension is not available.');
}
}
作者:gmurayam
项目:cor
protected function setUp()
{
parent::setUp();
$this->tagManager = $this->getMock('\\OCP\\SystemTag\\ISystemTagManager');
$this->tagMapper = $this->getMock('\\OCP\\SystemTag\\ISystemTagObjectMapper');
$this->node = new \OCA\DAV\SystemTag\SystemTagsObjectMappingCollection(111, 'files', $this->tagManager, $this->tagMapper);
}
作者:evanj
项目:cor
public function setUp()
{
$this->userManager = $this->getMockBuilder('\\OCP\\IUserManager')->disableOriginalConstructor()->getMock();
$this->config = $this->getMockBuilder('\\OCP\\IConfig')->disableOriginalConstructor()->getMock();
$this->connector = new \OCA\DAV\Connector\Sabre\Principal($this->config, $this->userManager);
parent::setUp();
}
作者:heldern
项目:owncloud8-extende
protected function tearDown()
{
$conn = \OC_DB::getConnection();
$conn->executeQuery('DELETE FROM `*PREFIX*vcategory_to_object`');
$conn->executeQuery('DELETE FROM `*PREFIX*vcategory`');
parent::tearDown();
}
作者:rchicol
项目:owncloud-cor
protected function tearDown()
{
if ($this->instance) {
$this->instance->clear();
}
parent::tearDown();
}
作者:julakal
项目:cor
protected function setUp()
{
parent::setUp();
self::$logs = array();
$this->config = $this->getMockBuilder('\\OC\\SystemConfig')->disableOriginalConstructor()->getMock();
$this->logger = new Log('Test\\Logger', $this->config);
}
作者:ninjasilico
项目:cor
public function setUp() {
parent::setUp();
$this->view = $this->getMockBuilder('OC\Files\View')
->disableOriginalConstructor()
->getMock();
$this->userManager = $this->getMockBuilder('OC\User\Manager')
->disableOriginalConstructor()
->getMock();
$this->groupManager = $this->getMockBuilder('OC\Group\Manager')
->disableOriginalConstructor()
->getMock();
$this->config = $this->getMockBuilder('OCP\IConfig')
->disableOriginalConstructor()
->getMock();
$this->util = new Util(
$this->view,
$this->userManager,
$this->groupManager,
$this->config
);
}
作者:GitHubUser423
项目:cor
public function setUp()
{
parent::setUp();
$this->request = $this->getMockBuilder('\\OCP\\IRequest')->disableOriginalConstructor()->getMock();
$this->externalManager = $this->getMockBuilder('\\OCA\\Files_Sharing\\External\\Manager')->disableOriginalConstructor()->getMock();
$this->clientService = $this->getMockBuilder('\\OCP\\Http\\Client\\IClientService')->disableOriginalConstructor()->getMock();
}
作者:rchicol
项目:owncloud-cor
protected function setUp()
{
parent::setUp();
$this->tagManager = $this->getMock('\\OCP\\SystemTag\\ISystemTagManager');
$this->tagMapper = $this->getMock('\\OCP\\SystemTag\\ISystemTagObjectMapper');
$this->user = $this->getMock('\\OCP\\IUser');
}
作者:rchicol
项目:owncloud-cor
protected function setUp()
{
parent::setUp();
$this->user = new DummyUser('foo', \OC::$server->getTempManager()->getTemporaryFolder());
$this->storage = new \OC\Files\Storage\Home(array('user' => $this->user));
$this->cache = $this->storage->getCache();
}
作者:ninjasilico
项目:cor
public function setUp() {
parent::setUp();
$this->request = $this->getMockBuilder('\OCP\IRequest')
->disableOriginalConstructor()->getMock();
$this->config = $this->getMockBuilder('\OCP\IConfig')
->disableOriginalConstructor()->getMock();
$this->config = $this->getMockBuilder('\OCP\IConfig')
->disableOriginalConstructor()->getMock();
$this->clientService = $this->getMockBuilder('\OCP\Http\Client\IClientService')
->disableOriginalConstructor()->getMock();
$this->util = $this->getMockBuilder('\OC_Util')
->disableOriginalConstructor()->getMock();
$this->urlGenerator = $this->getMockBuilder('\OCP\IURLGenerator')
->disableOriginalConstructor()->getMock();
$this->checkSetupController = new CheckSetupController(
'settings',
$this->request,
$this->config,
$this->clientService,
$this->urlGenerator,
$this->util
);
}
作者:0x17d
项目:cor
protected function setUp()
{
parent::setUp();
$connection = \OC::$server->getDatabaseConnection();
$this->expressionBuilder = new ExpressionBuilder($connection);
$this->doctrineExpressionBuilder = new DoctrineExpressionBuilder($connection);
}
作者:rchicol
项目:owncloud-cor
public function setUp()
{
parent::setUp();
$this->urlGenerator = $this->getMock('OCP\\IURLGenerator');
$this->il10n = $this->getMock('OCP\\IL10N');
$this->addressHandler = new AddressHandler($this->urlGenerator, $this->il10n);
}
作者:gmurayam
项目:cor
public function setUp()
{
parent::setUp();
$this->config = $this->getMock('\\OCP\\IConfig');
$this->userManager = $this->getMock('\\OCP\\IUserManager');
$this->scanFiles = $this->getMockBuilder('\\OCA\\Files\\BackgroundJob\\ScanFiles')->setConstructorArgs([$this->config, $this->userManager])->setMethods(['runScanner'])->getMock();
}
作者:rosario
项目:cor
protected function tearDown()
{
$result = \OC_User::deleteUser(self::$user);
$this->assertTrue($result);
$this->logout();
parent::tearDown();
}
作者:DanielTosell
项目:ownclou
protected function setUp()
{
parent::setUp();
$this->tag = new SystemTag(1, 'Test', true, false);
$this->tagManager = $this->getMock('\\OCP\\SystemTag\\ISystemTagManager');
$this->node = new \OCA\DAV\SystemTag\SystemTagNode($this->tag, $this->tagManager);
}
作者:quality12
项目:cor
public function tearDown()
{
$userManager = \OC::$server->getUserManager();
$userManager->get($this->user)->delete();
unset($_SERVER['HTTP_OC_CHUNKED']);
parent::tearDown();
}