2021-07-10 00:59:20 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Database\Factories\Engelsystem\Models;
|
|
|
|
|
|
|
|
use Engelsystem\Models\Message;
|
|
|
|
use Engelsystem\Models\User\User;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
|
|
|
|
class MessageFactory extends Factory
|
|
|
|
{
|
|
|
|
/** @var string */
|
2022-12-15 19:50:56 +01:00
|
|
|
protected $model = Message::class; // phpcs:ignore
|
2021-07-10 00:59:20 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @return array
|
|
|
|
*/
|
2022-12-14 19:15:20 +01:00
|
|
|
public function definition(): array
|
2021-07-10 00:59:20 +02:00
|
|
|
{
|
|
|
|
return [
|
|
|
|
'user_id' => User::factory(),
|
|
|
|
'receiver_id' => User::factory(),
|
|
|
|
'read' => $this->faker->boolean(),
|
|
|
|
'text' => $this->faker->text(),
|
|
|
|
];
|
|
|
|
}
|
|
|
|
}
|