Skip to content

Commit 8cfdd11

Browse files
authored
Add schema creation
1 parent f3d032b commit 8cfdd11

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/Unit/ValidationRuleParsingTest.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
namespace Knuckles\Scribe\Tests\Unit;
44

55
use Illuminate\Foundation\Application;
6+
use Illuminate\Support\Facades\Schema;
67
use Illuminate\Support\Facades\Validator;
78
use Illuminate\Translation\Translator;
89
use Illuminate\Validation\Rule;
@@ -40,6 +41,11 @@ public function parse($validationRules, $customParameterData = []): array
4041
*/
4142
public function can_parse_supported_rules(array $ruleset, array $customInfo, array $expected)
4243
{
44+
// Needed for `exists` rule
45+
Schema::create('users', function (Blueprint $table) {
46+
$table->id();
47+
});
48+
4349
$results = $this->strategy->parse($ruleset, $customInfo);
4450

4551
$parameterName = array_keys($ruleset)[0];

0 commit comments

Comments
 (0)