protected override void ConfigureServices(HostBuilderContext context, IServiceCollection services) { base.ConfigureServices(context, services); _fakeExceptionSubscriber = Substitute.For <IExceptionSubscriber>(); services.AddSingleton(_fakeExceptionSubscriber); }
protected override void ConfigureServices(HostBuilderContext context, IServiceCollection services) { base.ConfigureServices(context, services); FakeExceptionSubscriber = Substitute.For <IExceptionSubscriber>(); services.AddSingleton(FakeExceptionSubscriber); services.Configure <AbpAuthorizationExceptionHandlerOptions>(options => { options.AuthenticationScheme = "Cookie"; }); }