Hi, All My Tests were running perfect last week then I ran them again after a little coding and now get this error it seems very general but I can't solve it.
I Can run my Store ,Update, and Destroy methods and they pass but the get actions for Index,Create and Show Fail.
UnexpectedValueException : Invalid route action: [request].
/**
* @test
* @dataProvider requests
*/
public function test_Global_Users_Are_Allowed_User_Access(Closure $sendRequest)
{
$this->withoutExceptionHandling();
//User Trying to complete the action
$this->login(User::factory()->global()->create());
//Model trying to be accessed
$user = User::factory()->temporary()->create();
/** @var TestResponse $response */
$response = $sendRequest->call($this, $user);
//expected Response
$this->assertTrue(in_array($response->status(), [200, 302]));
}
public function requests(): \Generator
{
yield [fn(User $user) => $this->get(action([\App\Http\Controllers\UserController::class, 'index']))];
yield [fn(User $user) => $this->get(action([\App\Http\Controllers\UserController::class, 'create']))];
yield [fn(User $user) => $this->get(action([\App\Http\Controllers\UserController::class, 'show'], $user->id))];
yield [fn(User $user) => $this->post(action([\App\Http\Controllers\UserController::class, 'store']))];
yield [fn(User $user) => $this->patch(action([\App\Http\Controllers\UserController::class, 'update'], $user->id))];
yield [fn(User $user) => $this->delete(action([\App\Http\Controllers\UserController::class, 'destroy'], $user->id))];
}