Implemented interface member:
property
ApplicationServices
Microsoft.AspNetCore.Builder.IApplicationBuilder.ApplicationServices
14 writes to ApplicationServices
Microsoft.AspNetCore (1)
WebApplication.cs (1)
74
set => ApplicationBuilder.
ApplicationServices
= value;
Microsoft.AspNetCore.Hosting.Tests (13)
StartupManagerTests.cs (13)
301
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
324
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
350
app.
ApplicationServices
= startup.ConfigureServicesDelegate(new ServiceCollection());
397
app.
ApplicationServices
= startup.ConfigureServicesDelegate(new ServiceCollection());
460
app.
ApplicationServices
= startup.ConfigureServicesDelegate(new ServiceCollection());
477
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
495
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
512
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
541
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
556
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
572
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
588
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
634
app.
ApplicationServices
= startup.ConfigureServicesDelegate(serviceCollection);
40 references to ApplicationServices
Microsoft.AspNetCore (1)
WebApplication.cs (1)
73
get => ApplicationBuilder.
ApplicationServices
;
Microsoft.AspNetCore.Hosting.Tests (14)
StartupManagerTests.cs (14)
353
var options = app.
ApplicationServices
.GetRequiredService<IOptions<FakeOptions>>().Value;
400
var options = app.
ApplicationServices
.GetRequiredService<IOptions<FakeOptions>>().Value;
461
Assert.NotNull(app.
ApplicationServices
);
463
Assert.NotNull(app.
ApplicationServices
);
480
var foo = app.
ApplicationServices
.GetRequiredService<StartupWithConfigureServices.IFoo>();
498
var foo = app.
ApplicationServices
.GetRequiredService<SimpleService>();
558
Assert.IsType<MyContainer>(app.
ApplicationServices
);
559
Assert.True(((MyContainer)app.
ApplicationServices
).FancyMethodCalled);
574
Assert.IsType<MyContainer>(app.
ApplicationServices
);
575
Assert.True(((MyContainer)app.
ApplicationServices
).FancyMethodCalled);
590
Assert.IsType<MyContainer>(app.
ApplicationServices
);
591
Assert.Equal(((MyContainer)app.
ApplicationServices
).Environment, Environments.Production);
636
Assert.NotNull(app.
ApplicationServices
);
637
Assert.IsNotType<MyContainer>(app.
ApplicationServices
);
Microsoft.AspNetCore.Identity.EntityFrameworkCore.Test (18)
CustomSchemaTest.cs (2)
34
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
42
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
DefaultPocoTest.cs (2)
44
var userStore = _builder.
ApplicationServices
.GetRequiredService<IUserStore<IdentityUser>>();
45
var userManager = _builder.
ApplicationServices
.GetRequiredService<UserManager<IdentityUser>>();
EmptySchemaTest.cs (2)
34
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
42
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
MaxKeyLengthSchemaTest.cs (2)
34
using (var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope())
52
using (var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope())
UserOnlyCustomContextTest.cs (2)
89
var userStore = _builder.
ApplicationServices
.GetRequiredService<IUserStore<IdentityUser>>();
90
var userManager = _builder.
ApplicationServices
.GetRequiredService<UserManager<IdentityUser>>();
UserOnlyTest.cs (4)
50
var userStore = _builder.
ApplicationServices
.GetRequiredService<IUserStore<IdentityUser>>();
51
var userManager = _builder.
ApplicationServices
.GetRequiredService<UserManager<IdentityUser>>();
66
var userStore = _builder.
ApplicationServices
.GetRequiredService<IUserStore<IdentityUser>>();
67
var manager = _builder.
ApplicationServices
.GetRequiredService<UserManager<IdentityUser>>();
VersionOneSchemaTest.cs (2)
36
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
44
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
VersionTwoSchemaTest.cs (2)
36
var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
44
using var scope = _builder.
ApplicationServices
.GetRequiredService<IServiceScopeFactory>().CreateScope();
Microsoft.AspNetCore.Identity.InMemory.Test (4)
ControllerTest.cs (4)
48
var userManager = app.
ApplicationServices
.GetRequiredService<UserManager<PocoUser>>();
49
var signInManager = app.
ApplicationServices
.GetRequiredService<SignInManager<PocoUser>>();
98
var userManager = app.
ApplicationServices
.GetRequiredService<UserManager<PocoUser>>();
99
var signInManager = app.
ApplicationServices
.GetRequiredService<SignInManager<PocoUser>>();
Microsoft.AspNetCore.Mvc.Core.Test (1)
Builder\MvcApplicationBuilderExtensionsTest.cs (1)
53
var endpointDataSource = appBuilder.
ApplicationServices
Microsoft.AspNetCore.Owin (1)
OwinExtensions.cs (1)
117
}, builder.
ApplicationServices
);
Microsoft.AspNetCore.Routing.Tests (1)
Builder\EndpointRoutingApplicationBuilderExtensionsTest.cs (1)
323
var routeOptions = app.
ApplicationServices
.GetRequiredService<IOptions<RouteOptions>>();