Skip to content

Commit

Permalink
Add basic test case.
Browse files Browse the repository at this point in the history
  • Loading branch information
austinkregel committed Oct 16, 2022
1 parent 86864ad commit 13dc4e5
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?php

namespace Spork\Food\Tests;

use Illuminate\Database\Eloquent\Factories\Factory;
use Orchestra\Testbench\TestCase as TestbenchTestCase;
use Spork\Food\FoodServiceProvider.php;

class TestCase extends TestbenchTestCase
{
protected function setUp(): void
{
parent::setUp();

Factory::guessFactoryNamesUsing(
fn (string $modelName) => 'Spork\\Food\\Database\\Factories\\'.class_basename($modelName).'Factory'
);
}

protected function getPackageProviders($app)
{
return [
FoodServiceProvider.php::class,
];
}
}

0 comments on commit 13dc4e5

Please sign in to comment.