Skip to content

Commit

Permalink
sync: Update fixture hash to match testing cost
Browse files Browse the repository at this point in the history
  • Loading branch information
realodix committed Jan 16, 2024
1 parent fdd6afe commit 3f2e058
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion database/factories/UserFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@

use App\Models\User;
use Illuminate\Database\Eloquent\Factories\Factory;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Str;

/**
* @extends Factory<User>
*/
class UserFactory extends Factory
{
protected static ?string $password;

/**
* The name of the factory's corresponding model.
*
Expand All @@ -32,7 +35,7 @@ public function definition(): array
'name' => fake()->name(),
'email' => fake()->unique()->safeEmail(),
'email_verified_at' => now(),
'password' => '$2y$12$Z/vhVO3e.UXKaG11EWgxc.EL7uej3Pi1M0Pq0orF5cbFGtyVh0V3C', // password
'password' => static::$password ??= Hash::make('password'),
'remember_token' => Str::random(10),
];
}
Expand Down

0 comments on commit 3f2e058

Please sign in to comment.