mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 15:57:21 +01:00
moved old Expectation in CoreExpectation.php and made Expectation.php a decorator for it
This commit is contained in:
@ -1,7 +1,5 @@
|
||||
<?php
|
||||
|
||||
use PHPUnit\Framework\ExpectationFailedException;
|
||||
|
||||
it('gives access the the underlying expectException', function () {
|
||||
$this->expectException(InvalidArgumentException::class);
|
||||
|
||||
@ -39,7 +37,3 @@ it('can just define the message if given condition is true', function () {
|
||||
it('can just define the message if given condition is 1', function () {
|
||||
throw new Exception('Something bad happened');
|
||||
})->throwsIf(1, 'Something bad happened');
|
||||
|
||||
it('can handle a skipped test if it is trying to catch an exception', function () {
|
||||
expect(1)->toBe(2);
|
||||
})->throws(ExpectationFailedException::class)->skip('this test should be skipped')->only();
|
||||
|
||||
Reference in New Issue
Block a user