sebastianbergmann/phpunit — Issue #403: Test Failures with PHP 5.4
Author: sebastianbergmann
Created: 2011-11-11 10:00:25+00:00
State: open

`assertEquals()` is broken for `-INF` comparisons on PHP 5.4.

➜ phpunit git:(3.6) phpunit
PHPUnit @package_version@ by Sebastian Bergmann.

Configuration read from /usr/local/src/phpunit/phpunit.xml.dist

............................................................... 63 / 848 ( 7%)
............................................................... 126 / 848 ( 14%)
..................................................F............ 189 / 848 ( 22%)
............................................................... 252 / 848 ( 29%)
..........................................................F.... 315 / 848 ( 37%)
............................................................... 378 / 848 ( 44%)
............................................................... 441 / 848 ( 52%)
............................................................... 504 / 848 ( 59%)
............................................................... 567 / 848 ( 66%)
............................................................... 630 / 848 ( 74%)
............................................................... 693 / 848 ( 81%)
............................................................... 756 / 848 ( 89%)
............................................................... 819 / 848 ( 96%)
.............................

Time: 19 seconds, Memory: 46.50Mb

There were 2 failures:

1) Framework_AssertTest::testAssertSameSucceeds with data set #5 (-INF, -INF)
Failed asserting that -INF is identical to -INF.

/usr/local/src/phpunit/PHPUnit/Framework/Constraint.php:141
/usr/local/src/phpunit/PHPUnit/Framework/Constraint/IsIdentical.php:131
/usr/local/src/phpunit/PHPUnit/Framework/Assert.php:2100
/usr/local/src/phpunit/PHPUnit/Framework/Assert.php:1061
/usr/local/src/phpunit/Tests/Framework/AssertTest.php:776
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:918
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:780
/usr/local/src/phpunit/PHPUnit/Framework/TestResult.php:649
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:727
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:772
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:745
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:705
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:705
/usr/local/src/phpunit/PHPUnit/TextUI/TestRunner.php:325
/usr/local/src/phpunit/PHPUnit/TextUI/Command.php:187
/usr/local/src/phpunit/PHPUnit/TextUI/Command.php:125
/usr/local/src/phpunit/phpunit.php:44

2) Framework_AssertTest::testAssertNotSameFails with data set #5 (-INF, -INF)

/usr/local/src/phpunit/PHPUnit/Framework/Assert.php:2530
/usr/local/src/phpunit/Tests/Framework/AssertTest.php:819
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:918
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:780
/usr/local/src/phpunit/PHPUnit/Framework/TestResult.php:649
/usr/local/src/phpunit/PHPUnit/Framework/TestCase.php:727
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:772
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:745
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:705
/usr/local/src/phpunit/PHPUnit/Framework/TestSuite.php:705
/usr/local/src/phpunit/PHPUnit/TextUI/TestRunner.php:325
/usr/local/src/phpunit/PHPUnit/TextUI/Command.php:187
/usr/local/src/phpunit/PHPUnit/TextUI/Command.php:125
/usr/local/src/phpunit/phpunit.php:44

FAILURES!
Tests: 848, Assertions: 1392, Failures: 2.

Writing code coverage data to XML file, this may take a moment.

Generating code coverage report, this may take a moment.