mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 15:57:21 +01:00
feat(expect): handle property calls to opposite expectations
This commit is contained in:
@ -2,6 +2,9 @@
|
||||
PASS Tests\CustomTestCase\ExecutedTest
|
||||
✓ that gets executed
|
||||
|
||||
PASS Tests\Expect\not
|
||||
✓ not property calls
|
||||
|
||||
PASS Tests\Expect\toBe
|
||||
✓ expect true → toBeTrue → and false → toBeFalse
|
||||
✓ strict comparisons
|
||||
@ -309,5 +312,5 @@
|
||||
WARN Tests\Visual\Success
|
||||
- visual snapshot of test suite on success
|
||||
|
||||
Tests: 6 skipped, 182 passed
|
||||
Time: 5.72s
|
||||
Tests: 6 skipped, 183 passed
|
||||
Time: 5.77s
|
||||
|
||||
10
tests/Expect/not.php
Normal file
10
tests/Expect/not.php
Normal file
@ -0,0 +1,10 @@
|
||||
<?php
|
||||
|
||||
test('not property calls', function () {
|
||||
expect(true)
|
||||
->toBeTrue()
|
||||
->not()->toBeFalse()
|
||||
->not->toBeFalse
|
||||
->and(false)
|
||||
->toBeFalse();
|
||||
});
|
||||
Reference in New Issue
Block a user