Skip to content

Commit

Permalink
feat: add test support for exists rule in supportedRules yield
Browse files Browse the repository at this point in the history
  • Loading branch information
lotfimostafa committed Sep 4, 2024
1 parent 7834198 commit f3d032b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/Unit/ValidationRuleParsingTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -439,6 +439,13 @@ public static function supportedRules()
'description' => 'Must be accepted.',
],
];
yield 'exists' => [
['exists_param' => 'exists:users,id'],
[],
[
'description' => 'The <code>id</code> of an existing record in the users.',
],
];
yield 'unsupported' => [
['unsupported_param' => [new DummyValidationRule, 'bail']],
['unsupported_param' => ['description' => $description]],
Expand Down

0 comments on commit f3d032b

Please sign in to comment.