diff --git a/cake/tests/lib/reporter/cake_base_reporter.php b/cake/tests/lib/reporter/cake_base_reporter.php index 8aa65ba01..c45036cd7 100644 --- a/cake/tests/lib/reporter/cake_base_reporter.php +++ b/cake/tests/lib/reporter/cake_base_reporter.php @@ -259,6 +259,7 @@ class CakeBaseReporter implements PHPUnit_Framework_TestListener { * @param float $time */ public function addSkippedTest(PHPUnit_Framework_Test $test, Exception $e, $time) { + $this->paintSkip($e, $test); } /** diff --git a/cake/tests/lib/reporter/cake_html_reporter.php b/cake/tests/lib/reporter/cake_html_reporter.php index ef6c3bb5e..cf7424822 100755 --- a/cake/tests/lib/reporter/cake_html_reporter.php +++ b/cake/tests/lib/reporter/cake_html_reporter.php @@ -265,7 +265,9 @@ class CakeHtmlReporter extends CakeBaseReporter { $context = $message->getTrace(); $realContext = $context[3]; $class = new ReflectionClass($realContext['class']); - if ($class->getParentClass()->getName() === 'PHPUnit_Framework_TestCase') { + $deeper = $class->getParentClass()->getName() === 'PHPUnit_Framework_TestCase'; + $deeper = $deeper || !$class->isSubclassOf('PHPUnit_Framework_TestCase'); + if ($deeper) { $realContext = $context[4]; $context = $context[3]; } else { @@ -342,12 +344,13 @@ class CakeHtmlReporter extends CakeBaseReporter { * Prints the message for skipping tests. * * @param string $message Text of skip condition. + * @param PHPUnit_Framework_TestCase $test the test method skipped * @return void */ - public function paintSkip($message) { + public function paintSkip($message, $test) { echo "
  • \n"; echo "Skipped "; - echo $this->_htmlEntities($message); + echo $test->getName() . ': ' . $this->_htmlEntities($message->getMessage()); echo "
  • \n"; }