ExceptionInBeforeDoesNotMakeFatalErrorCept.php 679 B

123456789101112131415
  1. <?php
  2. $I = new CliGuy($scenario);
  3. $I->wantTo('see that exception in before does not cause fatal error in after');
  4. $I->amInPath('tests/data/exception_in_before');
  5. $I->executeFailCommand('run --xml --no-ansi');
  6. $I->seeInShellOutput('[Exception] in before');
  7. $I->dontSeeInShellOutput('[RuntimeException] in cept');
  8. $I->dontSeeInShellOutput('[RuntimeException] in cest');
  9. $I->dontSeeInShellOutput('[RuntimeException] in gherkin');
  10. $I->seeInShellOutput('Tests: 4, Assertions: 0, Errors: 5');
  11. //@todo if Unit format is ever fixed in PHPUnit, uncomment these lines
  12. //$I->dontSeeInShellOutput('[RuntimeException] in test');
  13. //$I->seeInShellOutput('Tests: 4, Assertions: 0, Errors: 4');