forked from eatvio/eatvio-infra
added tags factory
This commit is contained in:
28
database/factories/TagsFactory.php
Normal file
28
database/factories/TagsFactory.php
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
use FakerRestaurant\Provider\en_US\Restaurant;
|
||||
|
||||
/**
|
||||
* @extends \Illuminate\Database\Eloquent\Factories\Factory<\App\Models\PlanComment>
|
||||
*/
|
||||
class TagsFactory extends Factory
|
||||
{
|
||||
/**
|
||||
* Define the model's default state.
|
||||
*
|
||||
* @return array<string, mixed>
|
||||
*/
|
||||
public function definition(): array
|
||||
{
|
||||
$faker = \Faker\Factory::create();
|
||||
$this->faker->addProvider(new Restaurant($faker));
|
||||
return [
|
||||
'name' => $this->faker->foodName(),
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user