Permalink
Browse files

Add debug flag to flush output

  • Loading branch information...
shama committed Dec 15, 2011
1 parent 9d6ea57 commit b3396538b71340a3ca091af01845a40cc54d148f
Showing with 3 additions and 0 deletions.
  1. +3 −0 lib/Cake/TestSuite/CakeTestCase.php
@@ -147,6 +147,9 @@ public function tearDown() {
ClassRegistry::flush();
}
Configure::write($this->_configure);
+ if (isset($_GET['debug']) && $_GET['debug']) {
+ ob_flush();
+ }
}
/**

4 comments on commit b339653

@lorenzo

This comment has been minimized.

Show comment
Hide comment
@lorenzo

lorenzo Dec 15, 2011

Member

Is this documented? :p

Member

lorenzo replied Dec 15, 2011

Is this documented? :p

@markstory

This comment has been minimized.

Show comment
Hide comment
@markstory

markstory Dec 15, 2011

Member

Not yet. I don't really get why people use the webrunner anymore, but that's just me.

Member

markstory replied Dec 15, 2011

Not yet. I don't really get why people use the webrunner anymore, but that's just me.

@maurozadu

This comment has been minimized.

Show comment
Hide comment
@maurozadu

maurozadu Jan 11, 2012

Is there any chance to make the ob_flush() activated by default when running tests from web? I think it would be more consistent with previous versions of Cake. Most people expect to see pr(), echo() and debug() showed on screen and when that doesn’t happens we have to search a lot before to know what’s happening. Thanks!

Is there any chance to make the ob_flush() activated by default when running tests from web? I think it would be more consistent with previous versions of Cake. Most people expect to see pr(), echo() and debug() showed on screen and when that doesn’t happens we have to search a lot before to know what’s happening. Thanks!

@markstory

This comment has been minimized.

Show comment
Hide comment
@markstory

markstory Jan 12, 2012

Member

One drawback to outputting directly is you cannot send headers/cookies/sessions which makes it no different than using the command line runner.

Member

markstory replied Jan 12, 2012

One drawback to outputting directly is you cannot send headers/cookies/sessions which makes it no different than using the command line runner.

Please sign in to comment.