本文整理汇总了PHP中PHPUnit_Framework_TestCase::tearDown方法的典型用法代码示例。如果您正苦于以下问题:PHP PHPUnit_Framework_TestCase::tearDown方法的具体用法?PHP PHPUnit_Framework_TestCase::tearDown怎么用?PHP PHPUnit_Framework_TestCase::tearDown使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PHPUnit_Framework_TestCase
的用法示例。
在下文中一共展示了PHPUnit_Framework_TestCase::tearDown方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: tearDown
protected function tearDown()
{
parent::tearDown();
/** @var ObjectManagerInterface|\PHPUnit_Framework_MockObject_MockObject $objectManagerMock*/
$objectManagerMock = $this->getMock('Magento\\Framework\\ObjectManagerInterface');
\Magento\Framework\App\ObjectManager::setInstance($objectManagerMock);
}
示例2: tearDown
protected function tearDown()
{
$this->serializer = null;
$this->nativeArrayGateway = null;
$this->nativeObjectGateway = null;
parent::tearDown();
}
示例3: tearDown
/**
* Tear down process run after tests
* @return void
*/
protected function tearDown()
{
parent::tearDown();
if ($this->entityManager != null) {
$this->entityManager->getConnection()->close();
}
}
示例4: tearDown
protected function tearDown()
{
$this->generator = null;
$this->wordlist = null;
$this->roller = null;
parent::tearDown();
}
示例5: tearDown
public function tearDown()
{
parent::tearDown();
foreach (FakePaginatorModel::find() as $robot) {
$robot->delete();
}
}
示例6: tearDown
protected function tearDown()
{
unset($this->_coreAuthorization);
unset($this->_helperMock);
unset($this->_webapiAuthorization);
parent::tearDown();
}
示例7: tearDown
protected function tearDown()
{
foreach ($this->getTemplateNames() as $template) {
$config = $this->_includeConfig($template);
$file = $config['dist-installer-params']['file'];
switch ($template) {
case 'overwrite':
$oldFile = $file . '.old';
@copy($oldFile, $file);
@unlink($oldFile);
break;
case 'createdir':
@unlink($file);
@rmdir(dirname($file));
break;
case 'no-overwrite':
break;
default:
@unlink($file);
break;
}
}
foreach ($this->environmentBackup as $var => $value) {
if (false === $value) {
putenv($var);
} else {
putenv($var . '=' . $value);
}
}
parent::tearDown();
}
示例8: tearDown
public function tearDown()
{
$this->jobQueue = null;
$this->scheduler = null;
$this->beanstalk = null;
parent::tearDown();
}
示例9: tearDown
protected function tearDown()
{
if ($this->loader instanceof \Teknoo\States\Loader\LoaderInterface) {
spl_autoload_unregister(array($this->loader, 'loadClass'));
}
parent::tearDown();
}
示例10: tearDown
public function tearDown()
{
if ($this->resource !== null) {
fclose($this->resource);
}
parent::tearDown();
}
示例11: tearDown
/**
* Overrides the parent tearDown method.
*
* @return void
*
* @see PHPUnit_Framework_TestCase::tearDown()
* @since 3.6
*/
protected function tearDown()
{
unset($this->object);
unset($this->safeObject);
unset($this->safeObjectArrayTest);
parent::tearDown();
}
示例12: tearDown
public function tearDown()
{
parent::tearDown();
if ($this->cwd) {
$this->filesystem->remove($this->cwd);
}
}
示例13: tearDown
function tearDown()
{
parent::tearDown();
if (defined('IS_WPCOM') && IS_WPCOM) {
restore_current_blog();
}
}
示例14: tearDown
/**
* Tears down the fixture, for example, closes a network connection.
* This method is called after a test is executed.
*
* @return void
*/
protected function tearDown()
{
JFolder::delete(JPATH_TESTS . '/tmp/language');
unset($this->object);
unset($this->inspector);
parent::tearDown();
}
示例15: tearDown
protected function tearDown()
{
parent::tearDown();
$this->_instance->reset();
$this->_instance = null;
@unlink($this->_file);
}