gives back, in order to test the endpoints protected with the Authorize attribute. I don't want to call the login endpoint just before every test scenario to have a valid cookie, just want to mock it.
How can I achieve it?
Thank in advance.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Hi,
I'd like to mock the cookie that the
awat Request.HttpContext.SignInAsync("Cookies", claimsPrincipal);
gives back, in order to test the endpoints protected with the Authorize attribute. I don't want to call the login endpoint just before every test scenario to have a valid cookie, just want to mock it.
How can I achieve it?
Thank in advance.