Skip to content
Permalink
Browse files

Fix risky test warnings.

Fix the risky test warnings. PHPUnit has changed internally and no
longer closes a buffer when interacting with the test result.
  • Loading branch information...
markstory committed Oct 9, 2016
1 parent b03309f commit aae5191bea6859abaab9d49661fe9d791d17d9ac
@@ -649,7 +649,7 @@ public function testAssertNoRedirectFail()
{
$test = new AssertIntegrationTestCase('testBadAssertNoRedirect');
$result = $test->run();
ob_start();
$this->assertFalse($result->wasSuccessful());
$this->assertEquals(1, $result->failureCount());
}
@@ -130,7 +130,7 @@ public function testAssertHtmlBasic()
{
$test = new AssertHtmlTestCase('testAssertHtmlQuotes');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->errorCount());
$this->assertTrue($result->wasSuccessful());
$this->assertEquals(0, $result->failureCount());
@@ -225,7 +225,6 @@ public function testNumericValuesInExpectationForAssertHtml()
{
$test = new AssertHtmlTestCase('testNumericValuesInExpectationForAssertHtml');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->errorCount());
$this->assertTrue($result->wasSuccessful());
$this->assertEquals(0, $result->failureCount());
@@ -240,14 +239,12 @@ public function testBadAssertHtml()
{
$test = new AssertHtmlTestCase('testBadAssertHtml');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->errorCount());
$this->assertFalse($result->wasSuccessful());
$this->assertEquals(1, $result->failureCount());
$test = new AssertHtmlTestCase('testBadAssertHtml2');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->errorCount());
$this->assertFalse($result->wasSuccessful());
$this->assertEquals(1, $result->failureCount());
@@ -267,7 +264,6 @@ public function testLoadFixturesOnDemand()
$test->fixtureManager = $manager;
$manager->expects($this->once())->method('loadSingle');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->errorCount());
}
@@ -281,12 +277,10 @@ public function testSkipIf()
{
$test = new FixturizedTestCase('testSkipIfTrue');
$result = $test->run();
ob_start();
$this->assertEquals(1, $result->skippedCount());
$test = new FixturizedTestCase('testSkipIfFalse');
$result = $test->run();
ob_start();
$this->assertEquals(0, $result->skippedCount());
}

0 comments on commit aae5191

Please sign in to comment.
You can’t perform that action at this time.