Beispiel #1
0
 public function case_raise_more_exceptions()
 {
     $this->given($exception1 = new SUT('bar'), $barLine = __LINE__, $exception2 = new SUT('baz'), $bazLine = __LINE__, $group = new SUT('foo'), $fooLine = __LINE__, $group[] = $exception1, $group[] = $exception2)->when($result = $group->raise())->then->string($result)->isEqualTo(__METHOD__ . '(): (0) foo' . "\n" . 'in ' . __FILE__ . ' at line ' . $fooLine . '.' . "\n\n" . 'Contains the following exceptions:' . "\n\n" . '  • ' . __METHOD__ . '(): (0) bar' . "\n" . '    in ' . __FILE__ . ' at line ' . $barLine . '.' . "\n\n" . '  • ' . __METHOD__ . '(): (0) baz' . "\n" . '    in ' . __FILE__ . ' at line ' . $bazLine . '.');
 }