function testNoExceptionsInQueueMeansNoTestMessages()
 {
     $test = new MockSimpleTestCase();
     $test->expectNever('assert');
     $queue = new SimpleExceptionTrap();
     $this->assertFalse($queue->isExpected($test, new Exception()));
 }
Example #2
0
 public function testExpectationMatchCancelsIncomingError()
 {
     $test = new MockSimpleTestCase();
     $test->expectOnce('assert', array(new IdenticalExpectation(new AnythingExpectation()), 'B', 'a message'));
     $test->setReturnValue('assert', true);
     $test->expectNever('error');
     $queue = new SimpleErrorQueue();
     $queue->setTestCase($test);
     $queue->expectError(new AnythingExpectation(), 'a message');
     $queue->add(1024, 'B', 'b.php', 100);
 }