Ejemplo n.º 1
0
 /**
  * @return void
  */
 public function tearDown()
 {
     AssertionBuilder::validateLastAssertion();
     $this->mockManager->validateMocks();
     if ($this->verifyFailures) {
         $count = count($this->verifyFailures);
         $message = "{$count} verify failure" . ($count === 1 ? '' : 's') . ":";
         $message .= "\n\n" . implode("\n\n", $this->verifyFailures);
         throw new PHPUnit_Framework_AssertionFailedError($message);
     }
     SyntaxRenderer::$color = true;
     parent::tearDown();
 }
 protected function expectFailure($message)
 {
     $this->setExpectedException('Concise\\Core\\DidNotMatchException', $message);
     SyntaxRenderer::$color = false;
 }
Ejemplo n.º 3
0
 public function testCustomMessageWithAssertionFailure()
 {
     SyntaxRenderer::$color = false;
     $this->assert('Something', true)->equals(false);
 }