mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 07:47:22 +01:00
Uses Collision ^7.0
This commit is contained in:
@ -21,11 +21,15 @@ it('skips with message')
|
||||
->assertTrue(false);
|
||||
|
||||
it('skips with truthy closure condition')
|
||||
->skip(function () { return '1'; })
|
||||
->skip(function () {
|
||||
return '1';
|
||||
})
|
||||
->assertTrue(false);
|
||||
|
||||
it('do not skips with falsy closure condition')
|
||||
->skip(function () { return false; })
|
||||
->skip(function () {
|
||||
return false;
|
||||
})
|
||||
->assertTrue(true);
|
||||
|
||||
it('skips with condition and message')
|
||||
@ -37,10 +41,16 @@ it('skips when skip after assertion')
|
||||
->skip();
|
||||
|
||||
it('can use something in the test case as a condition')
|
||||
->skip(function () { return $this->shouldSkip; }, 'This test was skipped')
|
||||
->skip(function () {
|
||||
return $this->shouldSkip;
|
||||
}, 'This test was skipped')
|
||||
->assertTrue(false);
|
||||
|
||||
it('can user higher order callables and skip')
|
||||
->skip(function () { return $this->shouldSkip; })
|
||||
->expect(function () { return $this->shouldSkip; })
|
||||
->skip(function () {
|
||||
return $this->shouldSkip;
|
||||
})
|
||||
->expect(function () {
|
||||
return $this->shouldSkip;
|
||||
})
|
||||
->toBeFalse();
|
||||
|
||||
Reference in New Issue
Block a user