We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e4bead7 commit 1a1d7e4Copy full SHA for 1a1d7e4
src/Framework/TestCase.php
@@ -632,17 +632,8 @@ public function expectExceptionMessageRegExp($messageRegExp)
632
$this->expectedExceptionMessageRegExp = $messageRegExp;
633
}
634
635
- /**
636
- * @param $exception \Exception
637
- *
638
- * @throws Exception
639
- */
640
- public function expectExceptionObject($exception)
+ public function expectExceptionObject(Exception $exception)
641
{
642
- if (!\is_a($exception, \Exception::class)) {
643
- throw InvalidArgumentHelper::factory(1, 'exception');
644
- }
645
-
646
$this->expectException(get_class($exception));
647
$this->expectExceptionMessage($exception->getMessage());
648
$this->expectExceptionCode($exception->getCode());
0 commit comments