Level 1
i have found a solution: https://gist.github.com/msonowal/e859d6c6e63074d34a65614aaa4f0506
I'm building an api using for authorization Laravel Passport package and I would like to functional test my routes, problem is that I have used client_credentials grant type and recommended code to test api is not working.
Passport::actingAs(
factory(User::class)->create(),
['create-servers']
);
How to create in test environment access token and use it to access my resources?
Currently im getting "unauthorized" response.
Please or to participate in this conversation.