1<?php 2 3namespace Database\Factories; 4 5use App\Models\Port; 6use Illuminate\Database\Eloquent\Factories\Factory; 7 8class PortFactory extends Factory 9{ 10 /** 11 * The name of the factory's corresponding model. 12 * 13 * @var string 14 */ 15 protected $model = Port::class; 16 17 /** 18 * Define the model's default state. 19 * 20 * @return array 21 */ 22 public function definition() 23 { 24 return [ 25 'ifIndex' => $this->faker->unique()->numberBetween(), 26 'ifName' => $this->faker->text(20), 27 'ifDescr' => $this->faker->text(255), 28 'ifLastChange' => $this->faker->unixTime(), 29 ]; 30 } 31} 32