mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 07:47:22 +01:00
feat: allow string type in gt/lt expectations
This commit is contained in:
@ -16,6 +16,11 @@ test('passes with DateTime and DateTimeImmutable', function () {
|
||||
expect($now)->not->toBeLessThan($now);
|
||||
});
|
||||
|
||||
test('passes with strings', function () {
|
||||
expect('a')->toBeLessThan('b');
|
||||
expect('a')->not->toBeLessThan('a');
|
||||
});
|
||||
|
||||
test('failures', function () {
|
||||
expect(4)->toBeLessThan(4);
|
||||
})->throws(ExpectationFailedException::class);
|
||||
|
||||
Reference in New Issue
Block a user