07-20-2020 03:24 AM
I am trying to setup some integration tests for a web API. Some of the routes in the controller I am interested in use the [Authorize] attribute, backed by JWT authentication using Identity Server 4, to prevent unauthorized from accessing certain resources.
I'd like to "disable" authorization for testing purposes: replacing Identity Server with a "fake" authorizer that always gives green light to all requests.
I am using TestServer to run the API I want to test in memory and I'd like to use ConfigureTestServices to override the authorisation method, but I can't find any easy way to stub/mock it.
Does anyone have any relevant experience with a similar problem?
11-27-2021 02:47 AM
One can access the Netgear router login portal via the web address. In case you are facing a problem in accessing the login page via a web address, you can take instant help from our expert technicians