本文整理汇总了PHP中TextReporter::paintFooter方法的典型用法代码示例。如果您正苦于以下问题:PHP TextReporter::paintFooter方法的具体用法?PHP TextReporter::paintFooter怎么用?PHP TextReporter::paintFooter使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TextReporter
的用法示例。
在下文中一共展示了TextReporter::paintFooter方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: paintFooter
/**
* Paints the end of the test with a summary of
* the passes and failures.
*
* @param string $test_name Name class of test.
* @access public
*/
function paintFooter($test_name)
{
parent::paintFooter($test_name);
echo 'Time taken by tests (in seconds): ' . $this->_timeDuration . "\n";
if (function_exists('memory_get_peak_usage')) {
echo 'Peak memory use: (in bytes): ' . number_format(memory_get_peak_usage()) . "\n";
}
}
示例2: paintFooter
function paintFooter($test_name)
{
parent::paintFooter($test_name);
$runner = lmbTestRunner::getCurrent();
print 'Tests time: ' . $runner->getRuntime() . " sec.\n";
if ($memory = $runner->getMemoryUsage()) {
print 'Tests memory usage: ' . $memory . " Mb.\n";
}
if ($this->failed_tests) {
print "=========== FAILED TESTS ===========\n";
print implode("\n", $this->failed_tests) . "\n";
}
}
示例3: paintFooter
/**
* Capture the attempt to display the final test results and insert the
* ANSI-color codes in place.
*
* @param string
* @see TextReporter
* @access public
*/
function paintFooter($test_name)
{
ob_start();
parent::paintFooter($test_name);
$output = trim(ob_get_clean());
if ($output) {
if ($this->getFailCount() + $this->getExceptionCount() == 0) {
$color = $this->_passColor;
} else {
$color = $this->_failColor;
}
$this->_setColor($color);
echo $output;
$this->_resetColor();
}
}
示例4: paintFooter
public function paintFooter($test_name)
{
parent::paintFooter($test_name);
echo 'Time: ' . $GLOBALS['TIME'] . "\n";
}
示例5: paintFooter
function paintFooter($test_name) {
parent::paintFooter($test_name);
}