本文整理匯總了PHP中UnitTestCase::after方法的典型用法代碼示例。如果您正苦於以下問題:PHP UnitTestCase::after方法的具體用法?PHP UnitTestCase::after怎麽用?PHP UnitTestCase::after使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類UnitTestCase
的用法示例。
在下文中一共展示了UnitTestCase::after方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: after
/**
* Decorates SimpleTest's implementation to auto-validate mock objects.
*/
public function after($method)
{
try {
$this->_mockery()->assertIsSatisfied();
} catch (Yay_NotSatisfiedException $e) {
$this->fail($e->getMessage());
}
$this->_mockery = null;
return parent::after($method);
}
示例2: after
/**
* Announces the end of a test.
*
* @param string $method Test method just finished.
* @return void
* @access public
*/
function after($method)
{
$isTestMethod = !in_array(strtolower($method), array('start', 'end'));
if (isset($this->_fixtures) && isset($this->db) && $isTestMethod) {
foreach ($this->_fixtures as $fixture) {
$fixture->truncate($this->db);
}
$this->__truncated = true;
} else {
$this->__truncated = false;
}
if (!in_array(strtolower($method), $this->methods)) {
$this->endTest($method);
}
$this->_should_skip = false;
parent::after($method);
}
示例3: after
/**
* Announces the end of a test.
*
* @param string $method Test method just finished.
*
* @access public
*/
function after($method)
{
if (isset($this->_fixtures) && isset($this->db) && !in_array(low($method), array('start', 'end'))) {
foreach ($this->_fixtures as $fixture) {
$query = $fixture->truncate();
if (isset($query) && $query !== false) {
$this->db->_execute($query);
}
}
}
if (!in_array(low($method), $this->methods)) {
$this->endTest($method);
}
parent::after($method);
}
示例4: after
/**
* Announces the end of the test. Includes private clean up.
* @param string $method Test method just finished.
* @access public
*/
function after($method)
{
parent::after($this->cleanCamelCase($method));
}
示例5: after
/**
* Announces the end of the test. Includes private clean up.
* @param string $method Test method just finished.
* @access public
*/
function after($method)
{
$this->unsetBrowser();
parent::after($method);
}
示例6: after
/**
* Announces the end of a test.
*
* @param string $method Test method just finished.
*
* @access public
*/
function after($method)
{
if (isset($this->_fixtures) && isset($this->db) && !in_array(low($method), array('start', 'end'))) {
foreach ($this->_fixtures as $fixture) {
$this->db->truncate($fixture->table);
}
$this->__truncated = true;
} else {
$this->__truncated = false;
}
if (!in_array(low($method), $this->methods)) {
$this->endTest($method);
}
parent::after($method);
}