Skip to content

Commit a2903c3

Browse files
committed
Make TestCase::hasOutput() return true if "0" is outputted
TestCase::hasOutput() returns false when "0" is outputted, as it uses empty(), which returns false on the string "0".
1 parent 1c194d6 commit a2903c3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

PHPUnit/Framework/TestCase.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ public function getActualOutput()
393393
*/
394394
public function hasOutput()
395395
{
396-
if (empty($this->output)) {
396+
if (strlen($this->output) === 0) {
397397
return FALSE;
398398
}
399399

0 commit comments

Comments
 (0)