actingAs(User::factory()->superuser()->create()) ->get(route('manufacturers.index')) ->assertOk(); } public function testCannotSeedIfManufacturersExist() { Manufacturer::factory()->create(); $this->actingAs(User::factory()->superuser()->create()) ->post(route('manufacturers.seed')) ->assertStatus(302) ->assertSessionHas('error') ->assertRedirect(route('manufacturers.index')); } }