actingAs(User::factory()->create()) ->get(route('users.edit', User::factory()->create()->id)) ->assertForbidden(); } public function test_page_renders() { $this->actingAs(User::factory()->editUsers()->create()) ->get(route('users.edit', User::factory()->create()->id)) ->assertOk(); } public function test_edit_form_does_not_leak_company_id_into_location_select() { // Regression: the company_ids