Permalink
Browse files

Removing bogus code that doesn't work when tests fail.

  • Loading branch information...
markstory committed Jun 21, 2011
1 parent f353eb7 commit 734495d0c72a97e52d31307721a85c1dfcd4d8ba
Showing with 6 additions and 11 deletions.
  1. +6 −11 lib/Cake/Test/Case/Utility/FileTest.php
@@ -475,17 +475,12 @@ function _getTmpFile($paintSkip = true) {
};
if ($paintSkip) {
- $caller = 'test';
- if (function_exists('debug_backtrace')) {
- $trace = debug_backtrace();
- $caller = $trace[1]['function'] . '()';
- }
- $assertLine = new SimpleStackTrace(array(__FUNCTION__));
- $assertLine = $assertLine->traceMethod();
- $shortPath = substr($tmpFile, strlen(ROOT));
-
- $message = __d('cake_dev', '[FileTest] Skipping %s because "%s" not writeable!', $caller, $shortPath).$assertLine;
- $this->_reporter->paintSkip($message);
+ $trace = debug_backtrace();
+ $caller = $trace[0]['function'];
+ $shortPath = dirname($tmpFile);
+
+ $message = __d('cake_dev', '[FileTest] Skipping %s because "%s" not writeable!', $caller, $shortPath);
+ $this->markTestSkipped($message);
}
return false;
}

0 comments on commit 734495d

Please sign in to comment.