1211 instantiations of ServiceCollection
Aspire.EndToEnd.Tests (1)
tests\Shared\WorkloadTesting\AspireProject.cs (1)
455var services = new ServiceCollection();
Aspire.Hosting.Testing.Tests (2)
DistributedApplicationHttpClientExtensionsForTests.cs (1)
21var services = new ServiceCollection();
ResourceLoggerForwarderServiceTests.cs (1)
129return new ResourceNotificationService(NullLogger<ResourceNotificationService>.Instance, hostApplicationLifetime, new ServiceCollection().BuildServiceProvider(), resourceLoggerService);
Aspire.Hosting.Tests (6)
Dashboard\DashboardServiceTests.cs (4)
32var resourceNotificationService = new ResourceNotificationService(NullLogger<ResourceNotificationService>.Instance, new TestHostApplicationLifetime(), new ServiceCollection().BuildServiceProvider(), resourceLoggerService); 33var dashboardServiceData = new DashboardServiceData(resourceNotificationService, resourceLoggerService, NullLogger<DashboardServiceData>.Instance, new DashboardCommandExecutor(new ServiceCollection().BuildServiceProvider())); 84var resourceNotificationService = new ResourceNotificationService(loggerFactory.CreateLogger<ResourceNotificationService>(), new TestHostApplicationLifetime(), new ServiceCollection().BuildServiceProvider(), resourceLoggerService); 85using var dashboardServiceData = new DashboardServiceData(resourceNotificationService, resourceLoggerService, loggerFactory.CreateLogger<DashboardServiceData>(), new DashboardCommandExecutor(new ServiceCollection().BuildServiceProvider()));
ResourceCommandAnnotationTests.cs (1)
54ServiceProvider = new ServiceCollection().BuildServiceProvider()
tests\Aspire.Hosting.Testing.Tests\DistributedApplicationHttpClientExtensionsForTests.cs (1)
21var services = new ServiceCollection();
Aspire.Playground.Tests (1)
Infrastructure\DistributedApplicationExtensions.cs (1)
196var services = new ServiceCollection()
Aspire.Workload.Tests (1)
tests\Shared\WorkloadTesting\AspireProject.cs (1)
455var services = new ServiceCollection();
CustomEncryptorSample (1)
Program.cs (1)
15using (var services = new ServiceCollection()
EntityFrameworkCoreSample (1)
Program.cs (1)
17var services = new ServiceCollection()
InMemory.FunctionalTests (2)
HttpsConnectionMiddlewareTests.cs (1)
40serverOptions.ApplicationServices = new ServiceCollection()
HttpsTests.cs (1)
38serverOptions.ApplicationServices = new ServiceCollection()
InteropClient (1)
InteropClient.cs (1)
92var services = new ServiceCollection();
KeyManagementSample (1)
Program.cs (1)
16var serviceCollection = new ServiceCollection();
Microsoft.Arcade.Common (1)
MSBuildTaskBase.cs (1)
32ServiceCollection collection = new ServiceCollection();
Microsoft.AspNetCore.Antiforgery.Test (8)
AntiforgeryApplicationBuilderExtensionsTest.cs (1)
52var services = new ServiceCollection();
AntiforgeryOptionsSetupTest.cs (2)
21var serviceCollection = new ServiceCollection(); 41var serviceCollection = new ServiceCollection();
DefaultAntiforgeryTest.cs (5)
353var services = new ServiceCollection(); 1284var services = new ServiceCollection(); 1322var services = new ServiceCollection(); 1356var services = new ServiceCollection(); 1403var builder = new ServiceCollection();
Microsoft.AspNetCore.AsyncState.Tests (2)
AsyncContextHttpContextOfTTests.cs (1)
20var serviceCollection = new ServiceCollection()
AsyncStateHttpContextExtensionsTests.cs (1)
24var services = new ServiceCollection();
Microsoft.AspNetCore.Authentication.Core.Test (27)
AuthenticationSchemeProviderTests.cs (12)
17var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 30var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 43var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 59var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 77var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 93var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 109var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 134var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 147var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 161var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 178var services = new ServiceCollection().AddOptions() 197var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o =>
AuthenticationServiceTests.cs (13)
15var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 31var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 54var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 69var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 84var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 98var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 113var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 136var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 157var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 177var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 195var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 213var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o => 232var services = new ServiceCollection().AddOptions().AddAuthenticationCore(o =>
TokenExtensionTests.cs (2)
126var services = new ServiceCollection().AddOptions() 143var services = new ServiceCollection().AddOptions()
Microsoft.AspNetCore.Authentication.Test (42)
AuthenticationMiddlewareTests.cs (1)
205var serviceCollection = new ServiceCollection();
BearerTokenTests.cs (1)
16var services = new ServiceCollection();
CertificateTests.cs (1)
29var services = new ServiceCollection().ConfigureAuthTestServices();
CookieTests.cs (1)
287var services = new ServiceCollection();
JwtBearerTests_Handler.cs (5)
959var services = new ServiceCollection(); 995var services = new ServiceCollection().AddLogging(); 1020var services = new ServiceCollection(); 1049var services = new ServiceCollection(); 1069var services = new ServiceCollection();
OpenIdConnect\OpenIdConnectConfigurationTests.cs (9)
31var services = new ServiceCollection().ConfigureAuthTestServices(); 74var services = new ServiceCollection().ConfigureAuthTestServices(); 103var services = new ServiceCollection().ConfigureAuthTestServices(); 143var services = new ServiceCollection().ConfigureAuthTestServices(); 183var services = new ServiceCollection().ConfigureAuthTestServices(); 223var services = new ServiceCollection().ConfigureAuthTestServices(); 263var services = new ServiceCollection().ConfigureAuthTestServices(); 318var services = new ServiceCollection().ConfigureAuthTestServices(); 373var services = new ServiceCollection().ConfigureAuthTestServices();
OpenIdConnect\OpenIdConnectTests.cs (5)
424var services = new ServiceCollection().AddLogging(); 457var services = new ServiceCollection().AddLogging(); 494var services = new ServiceCollection().AddLogging(); 517var services = new ServiceCollection().AddLogging(); 544var services = new ServiceCollection().AddLogging();
PolicyTests.cs (5)
57var services = new ServiceCollection().ConfigureAuthTestServices(); 113var services = new ServiceCollection().ConfigureAuthTestServices(); 169var services = new ServiceCollection().ConfigureAuthTestServices(); 230var services = new ServiceCollection().ConfigureAuthTestServices(); 282var services = new ServiceCollection().ConfigureAuthTestServices();
SecureDataFormatTests.cs (1)
14var serviceCollection = new ServiceCollection();
SharedAuthenticationTests.cs (11)
29var services = new ServiceCollection().ConfigureAuthTestServices(); 86var services = new ServiceCollection().ConfigureAuthTestServices(); 129var services = new ServiceCollection().ConfigureAuthTestServices(); 169var services = new ServiceCollection().ConfigureAuthTestServices(); 218var services = new ServiceCollection().ConfigureAuthTestServices(); 248var services = new ServiceCollection().ConfigureAuthTestServices(); 287var services = new ServiceCollection().ConfigureAuthTestServices(); 326var services = new ServiceCollection().ConfigureAuthTestServices(); 395var services = new ServiceCollection().ConfigureAuthTestServices(); 464var services = new ServiceCollection().ConfigureAuthTestServices(); 538var services = new ServiceCollection().ConfigureAuthTestServices();
WsFederation\WsFederationTest.cs (1)
29var services = new ServiceCollection();
WsFederation\WsFederationTest_Handler.cs (1)
27var services = new ServiceCollection();
Microsoft.AspNetCore.Authorization.Test (15)
AuthorizationAppBuilderExtensionsTests.cs (2)
49var app = new ApplicationBuilder(new ServiceCollection().BuildServiceProvider()); 66var services = new ServiceCollection();
AuthorizationBuilderTests.cs (1)
111var services = new ServiceCollection();
AuthorizationMiddlewareResultHandlerTests.cs (1)
136var services = new ServiceCollection();
AuthorizationMiddlewareTests.cs (5)
251var services = new ServiceCollection() 291var services = new ServiceCollection() 360var services = new ServiceCollection() 997services ??= new ServiceCollection().BuildServiceProvider(); 1033var serviceCollection = new ServiceCollection();
DefaultAuthorizationServiceTests.cs (1)
16var services = new ServiceCollection();
PassThroughAuthorizationHandlerTests.cs (1)
14var services = new ServiceCollection();
PolicyEvaluatorTests.cs (4)
19var services = new ServiceCollection().AddSingleton<IAuthenticationService, SadAuthentication>(); 36var services = new ServiceCollection().AddSingleton<IAuthenticationService, EchoAuthentication>(); 55var services = new ServiceCollection().AddSingleton<IAuthenticationService>(auth); 161var services = new ServiceCollection()
Microsoft.AspNetCore.Components.Authorization.Tests (5)
AuthorizeRouteViewTest.cs (1)
30var serviceCollection = new ServiceCollection();
AuthorizeViewTest.cs (1)
566var serviceCollection = new ServiceCollection();
CascadingAuthenticationStateTest.cs (3)
36var services = new ServiceCollection(); 68var services = new ServiceCollection(); 121var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Endpoints.Tests (13)
Builder\RazorComponentsEndpointConventionBuilderExtensionsTest.cs (1)
273var collection = new ServiceCollection();
EndpointHtmlRendererTest.cs (4)
887httpContext.RequestServices = new ServiceCollection() 916httpContext.RequestServices = new ServiceCollection() 1009httpContext.RequestServices = new ServiceCollection() 1668var services = new ServiceCollection();
HotReloadServiceTests.cs (1)
217var services = new ServiceCollection();
ImportMapTest.cs (1)
22var services = new ServiceCollection();
RazorComponentEndpointDataSourceTest.cs (1)
220var services = new ServiceCollection();
RazorComponentEndpointInvokerTest.cs (1)
21var services = new ServiceCollection().AddRazorComponents()
RazorComponentResultTest.cs (1)
455var serviceCollection = new ServiceCollection()
RazorComponentsServiceCollectionExtensionsTest.cs (3)
19var services = new ServiceCollection(); 46var services = new ServiceCollection(); 75var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Performance (1)
RouteTableFactoryBenchmarks.cs (1)
18_serviceProvider = new ServiceCollection()
Microsoft.AspNetCore.Components.Server.Tests (13)
Circuits\CircuitHostTest.cs (7)
420serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 442serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 468serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 495serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 533serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 570serviceScope: new ServiceCollection().BuildServiceProvider().CreateAsyncScope()); 644var serviceCollection = new ServiceCollection();
Circuits\RemoteRendererTest.cs (1)
639var serviceCollection = new ServiceCollection();
Circuits\RenderBatchWriterTest.cs (1)
388: base(new ServiceCollection().BuildServiceProvider(), NullLoggerFactory.Instance)
ComponentEndpointRouteBuilderExtensionsTest.cs (1)
130var services = new ServiceCollection();
DependencyInjection\ComponentServiceCollectionExtensionsTest.cs (3)
17var services = new ServiceCollection(); 32var services = new ServiceCollection(); 54var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Tests (18)
CascadingParameterTest.cs (11)
445var services = new ServiceCollection(); 492var services = new ServiceCollection(); 520var services = new ServiceCollection(); 559var services = new ServiceCollection(); 574var services = new ServiceCollection(); 641var services = new ServiceCollection(); 696var services = new ServiceCollection(); 789var services = new ServiceCollection(); 804var services = new ServiceCollection(); 819var services = new ServiceCollection(); 840var services = new ServiceCollection();
ComponentFactoryTest.cs (1)
257return new ServiceCollection()
Lifetime\ComponentStatePersistenceManagerTest.cs (1)
239public TestRenderer() : base(new ServiceCollection().BuildServiceProvider(), NullLoggerFactory.Instance)
OwningComponentBaseTest.cs (1)
14var services = new ServiceCollection();
RouteViewTest.cs (1)
20var serviceCollection = new ServiceCollection();
Routing\RouterTest.cs (1)
21var services = new ServiceCollection();
Routing\RouteTableFactoryTests.cs (2)
18_serviceProvider = new ServiceCollection() 1124_serviceProvider = new ServiceCollection()
Microsoft.AspNetCore.Components.Web.Tests (10)
Forms\EditFormTest.cs (1)
19var services = new ServiceCollection();
Forms\InputNumberTest.cs (1)
18var services = new ServiceCollection();
Forms\Mapping\FormMappingScopeTest.cs (1)
18var serviceCollection = new ServiceCollection();
Forms\Mapping\SupplyParameterFromFormTest.cs (1)
63var services = new ServiceCollection();
HtmlRendering\HtmlRendererTest.cs (2)
1375var services = new ServiceCollection(); 1415var services = new ServiceCollection();
Virtualization\VirtualizeTest.cs (4)
23var serviceProvider = new ServiceCollection() 42var serviceProvider = new ServiceCollection() 61var serviceProvider = new ServiceCollection() 82var serviceProvider = new ServiceCollection()
Microsoft.AspNetCore.Components.WebAssembly (1)
Hosting\WebAssemblyHostBuilder.cs (1)
72Services = new ServiceCollection();
Microsoft.AspNetCore.Components.WebView.Test (1)
WebViewManagerTests.cs (1)
115return new ServiceCollection().AddSingleton<SingletonService>().AddScoped<ScopedService>();
Microsoft.AspNetCore.Components.WebViewE2E.Test (1)
BasicBlazorHybridTest.cs (1)
40var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.DataProtection.Extensions (1)
DataProtectionProvider.cs (1)
127var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.DataProtection.Tests (26)
ActivatorTests.cs (2)
16var serviceCollection = new ServiceCollection(); 72var serviceCollection = new ServiceCollection();
DataProtectionUtilityExtensionsTests.cs (4)
33var services = new ServiceCollection() 64var services = new ServiceCollection() 91var services = new ServiceCollection() 116var services = new ServiceCollection()
KeyManagement\KeyEscrowServiceProviderExtensionsTests.cs (3)
23var services = new ServiceCollection().BuildServiceProvider(); 42var serviceCollection = new ServiceCollection(); 74var serviceCollection = new ServiceCollection();
ServiceCollectionTests.cs (6)
21var services = new ServiceCollection() 32var services1 = new ServiceCollection() 38var services2 = new ServiceCollection() 52var serviceCollection = new ServiceCollection() 81var services = new ServiceCollection() 114var services = new ServiceCollection()
TypeForwardingActivatorTests.cs (2)
14var serviceCollection = new ServiceCollection(); 31var serviceCollection = new ServiceCollection();
XmlEncryption\CertificateXmlEncryptionTests.cs (1)
38var serviceCollection = new ServiceCollection();
XmlEncryption\EncryptedXmlDecryptorTests.cs (3)
34var services = new ServiceCollection() 52var services = new ServiceCollection() 70var services = new ServiceCollection()
XmlEncryption\XmlEncryptionExtensionsTests.cs (5)
40var serviceCollection = new ServiceCollection(); 67var serviceCollection = new ServiceCollection(); 101var serviceCollection = new ServiceCollection(); 133var serviceCollection = new ServiceCollection(); 184var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (15)
Latency\AddServerTimingHeaderMiddlewareTests.cs (1)
29using var serviceProvider = new ServiceCollection()
Latency\RequestLatencyTelemetryExtensionsTests.cs (4)
23RequestLatencyTelemetryServiceCollectionExtensions.AddRequestLatencyTelemetry(new ServiceCollection(), configure: null!)); 25RequestLatencyTelemetryServiceCollectionExtensions.AddRequestLatencyTelemetry(new ServiceCollection(), section: null!)); 33using var serviceProvider = new ServiceCollection() 58using var serviceProvider = new ServiceCollection()
Logging\HttpLoggingServiceExtensionsTests.cs (2)
34var services = new ServiceCollection(); 58var services = new ServiceCollection();
Logging\HttpUtilityExtensionsTests.cs (1)
27var sp = new ServiceCollection().AddHttpRouteUtilities().BuildServiceProvider();
Logging\LoggingOptionsValidationTests.cs (3)
22using var services = new ServiceCollection() 38using var services = new ServiceCollection() 54using var services = new ServiceCollection()
Logging\RequestHeadersEnricherExtensionsTests.cs (4)
25new ServiceCollection().AddRequestHeadersLogEnricher(null!)); 31using var sp = new ServiceCollection() 42using var serviceProvider = new ServiceCollection() 55using var serviceProvider = new ServiceCollection()
Microsoft.AspNetCore.Grpc.JsonTranscoding.Tests (5)
GrpcJsonTranscodingServiceExtensionsTests.cs (2)
15var services = new ServiceCollection(); 37var services = new ServiceCollection();
Infrastructure\TestHelpers.cs (1)
22var serviceCollection = new ServiceCollection();
JsonTranscodingServerCallContextTests.cs (1)
61var serviceCollection = new ServiceCollection();
JsonTranscodingServiceMethodProviderTests.cs (1)
264var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Grpc.Swagger.Tests (3)
GrpcSwaggerServiceExtensionsTests.cs (2)
22var services = new ServiceCollection(); 57var services = new ServiceCollection();
Infrastructure\OpenApiTestHelpers.cs (1)
18var services = new ServiceCollection();
Microsoft.AspNetCore.HeaderParsing.Tests (10)
HeaderParsingExtensionsTests.cs (8)
21using var services = new ServiceCollection() 33using var services = new ServiceCollection() 43using var services = new ServiceCollection() 53using var services = new ServiceCollection() 87var context = CreateContext(new ServiceCollection().AddSingleton(headerRegistry.Object)); 94var context = CreateContext(new ServiceCollection().AddHeaderParsing()); 108var context = CreateContext(new ServiceCollection().AddHeaderParsing()); 123services ??= new ServiceCollection();
HeaderParsingFeatureTests.cs (1)
37_services = new ServiceCollection();
HeaderRegistryTests.cs (1)
21_services = new ServiceCollection();
Microsoft.AspNetCore.HeaderPropagation.Tests (1)
HeaderPropagationIntegrationTest.cs (1)
80var services = new ServiceCollection();
Microsoft.AspNetCore.Hosting (2)
Internal\ServiceCollectionExtensions.cs (1)
12IServiceCollection clone = new ServiceCollection();
WebHostBuilder.cs (1)
265var services = new ServiceCollection();
Microsoft.AspNetCore.Hosting.Tests (41)
ConfigureBuilderTests.cs (1)
18var services = new ServiceCollection()
Fakes\Startup.cs (2)
53var services = new ServiceCollection().AddOptions(); 85var services = new ServiceCollection().AddOptions();
HostingApplicationTests.cs (1)
183var services = new ServiceCollection();
HostingMetricsTests.cs (1)
189var services = new ServiceCollection();
Http\DefaultHttpContextFactoryTests.cs (6)
15var services = new ServiceCollection() 33var services = new ServiceCollection() 55var services = new ServiceCollection() 69var services = new ServiceCollection() 87var services = new ServiceCollection() 105var services = new ServiceCollection()
StartupManagerTests.cs (30)
19var serviceCollection = new ServiceCollection(); 41var serviceCollection = new ServiceCollection(); 63var serviceCollection = new ServiceCollection(); 87var serviceCollection = new ServiceCollection(); 109var serviceCollection = new ServiceCollection(); 131var serviceCollection = new ServiceCollection(); 292var serviceCollection = new ServiceCollection(); 310var serviceCollection = new ServiceCollection(); 343var services = new ServiceCollection() 350app.ApplicationServices = startup.ConfigureServicesDelegate(new ServiceCollection()); 362var serviceCollection = new ServiceCollection(); 390var services = new ServiceCollection() 397app.ApplicationServices = startup.ConfigureServicesDelegate(new ServiceCollection()); 409var serviceCollection = new ServiceCollection(); 423var serviceCollection = new ServiceCollection(); 438var serviceCollection = new ServiceCollection(); 452var serviceCollection = new ServiceCollection(); 460app.ApplicationServices = startup.ConfigureServicesDelegate(new ServiceCollection()); 469var serviceCollection = new ServiceCollection(); 487var serviceCollection = new ServiceCollection(); 505var serviceCollection = new ServiceCollection(); 520var serviceCollection = new ServiceCollection(); 534var serviceCollection = new ServiceCollection(); 549var serviceCollection = new ServiceCollection(); 565var serviceCollection = new ServiceCollection(); 581var serviceCollection = new ServiceCollection(); 597var serviceCollection = new ServiceCollection(); 608var serviceCollection = new ServiceCollection(); 617var serviceCollection = new ServiceCollection(); 627var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Http.Connections.Tests (71)
HttpConnectionDispatcherTests.cs (71)
62var services = new ServiceCollection(); 86var services = new ServiceCollection(); 112var services = new ServiceCollection(); 149var services = new ServiceCollection(); 177var services = new ServiceCollection(); 223var services = new ServiceCollection(); 264var services = new ServiceCollection(); 303var services = new ServiceCollection(); 345var services = new ServiceCollection(); 383var services = new ServiceCollection(); 422var services = new ServiceCollection(); 462var services = new ServiceCollection(); 525var services = new ServiceCollection(); 593var services = new ServiceCollection(); 656var services = new ServiceCollection(); 719var services = new ServiceCollection(); 758var services = new ServiceCollection(); 855var services = new ServiceCollection(); 902var services = new ServiceCollection(); 931var services = new ServiceCollection(); 1006var services = new ServiceCollection(); 1039var services = new ServiceCollection(); 1067var services = new ServiceCollection(); 1103var services = new ServiceCollection(); 1139var services = new ServiceCollection(); 1190var services = new ServiceCollection(); 1285var services = new ServiceCollection(); 1325var services = new ServiceCollection(); 1370var services = new ServiceCollection(); 1410var services = new ServiceCollection(); 1439var services = new ServiceCollection(); 1485var services = new ServiceCollection(); 1550var services = new ServiceCollection(); 1614var services = new ServiceCollection(); 1645var services = new ServiceCollection(); 1679var services = new ServiceCollection(); 1714var services = new ServiceCollection(); 1756var services = new ServiceCollection(); 1802var services = new ServiceCollection(); 1834var services = new ServiceCollection(); 1886var services = new ServiceCollection(); 1940var services = new ServiceCollection(); 1987var services = new ServiceCollection(); 2019var serviceCollection = new ServiceCollection(); 2060var services = new ServiceCollection(); 2113var services = new ServiceCollection(); 2166var services = new ServiceCollection(); 2231var context = MakeRequest("/foo", connection, new ServiceCollection()); 2247context = MakeRequest("/foo", connection, new ServiceCollection()); 2266var services = new ServiceCollection(); 2292var services = new ServiceCollection(); 2321var services = new ServiceCollection(); 2350var services = new ServiceCollection(); 2383var services = new ServiceCollection(); 2457var services = new ServiceCollection(); 2554var services = new ServiceCollection(); 2616var services = new ServiceCollection(); 2673var services = new ServiceCollection(); 2732var services = new ServiceCollection(); 2772var services = new ServiceCollection(); 2821var services = new ServiceCollection(); 2848var services = new ServiceCollection(); 2878var services = new ServiceCollection(); 2925var services = new ServiceCollection(); 2961var services = new ServiceCollection(); 3012var services = new ServiceCollection(); 3067var services = new ServiceCollection(); 3112var services = new ServiceCollection(); 3152var services = new ServiceCollection(); 3574var services = new ServiceCollection(); 3693var services = new ServiceCollection();
Microsoft.AspNetCore.Http.Extensions.Tests (26)
ProblemDetailsDefaultWriterTest.cs (1)
694var services = new ServiceCollection();
ProblemDetailsServiceCollectionExtensionsTest.cs (10)
22var collection = new ServiceCollection(); 37var collection = new ServiceCollection(); 53var collection = new ServiceCollection(); 73var collection = new ServiceCollection(); 89var collection = new ServiceCollection(); 110var collection = new ServiceCollection(); 142var collection = new ServiceCollection(); 175var collection = new ServiceCollection(); 195var collection = new ServiceCollection(); 217var collection = new ServiceCollection();
RequestDelegateFactoryTests.cs (8)
1172var serviceCollection = new ServiceCollection(); 1342httpContext.RequestServices = new ServiceCollection() 1374httpContext.RequestServices = new ServiceCollection() 1403httpContext.RequestServices = new ServiceCollection() 1736var serviceCollection = new ServiceCollection(); 3019var serviceProvider = new ServiceCollection().AddSingleton(metadataService).BuildServiceProvider(); 3034var serviceProvider = new ServiceCollection().AddSingleton(metadataService).BuildServiceProvider(); 3262RequestServices = new ServiceCollection().AddSingleton(LoggerFactory).BuildServiceProvider(),
RequestDelegateGenerator\RequestDelegateCreationTestBase.cs (1)
210var serviceCollection = new ServiceCollection();
RequestDelegateGenerator\RequestDelegateCreationTests.cs (3)
270var serviceCollection = new ServiceCollection(); 299var serviceCollection = new ServiceCollection(); 302var emptyServices = new ServiceCollection().BuildServiceProvider();
RequestDelegateGenerator\RequestDelegateCreationTests.Responses.cs (3)
646httpContext.RequestServices = new ServiceCollection() 669httpContext.RequestServices = new ServiceCollection() 757httpContext.RequestServices = new ServiceCollection()
Microsoft.AspNetCore.Http.Microbenchmarks (1)
src\Http\Http.Extensions\test\RequestDelegateGenerator\RequestDelegateCreationTestBase.cs (1)
210var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Http.Results.Tests (44)
AcceptedAtRouteOfTResultTests.cs (1)
221var services = new ServiceCollection();
AcceptedAtRouteResultTests.cs (1)
131var services = new ServiceCollection();
AcceptedOfTResultTests.cs (1)
145var services = new ServiceCollection();
AcceptedResultTests.cs (1)
88var services = new ServiceCollection();
BadRequestOfTResultTests.cs (1)
181var services = new ServiceCollection();
BadRequestResultTests.cs (1)
94var services = new ServiceCollection();
ChallengeResultTests.cs (1)
66var services = new ServiceCollection();
ConflictOfTResultTests.cs (1)
159var services = new ServiceCollection();
ConflictResultTests.cs (1)
95var services = new ServiceCollection();
ContentResultTests.cs (1)
172var services = new ServiceCollection();
CreatedAtRouteOfTResultTests.cs (1)
190var services = new ServiceCollection();
CreatedAtRouteResultTests.cs (1)
136var services = new ServiceCollection();
CreatedOfTResultTests.cs (1)
187var services = new ServiceCollection();
CreatedResultTests.cs (1)
124var services = new ServiceCollection();
EmptyResultTests.cs (1)
48return new ServiceCollection().BuildServiceProvider();
FileContentResultTests.cs (1)
29httpContext.RequestServices = new ServiceCollection()
ForbidResultTests.cs (1)
133var services = new ServiceCollection();
HttpResultsHelperTests.cs (1)
244var services = new ServiceCollection();
InternalServerErrorOfTResultTests.cs (1)
181var services = new ServiceCollection();
InternalServerErrorResultTests.cs (1)
94var services = new ServiceCollection();
JsonResultTests.cs (1)
315var services = new ServiceCollection();
LocalRedirectResultTests.cs (1)
122var serviceCollection = new ServiceCollection();
NoContentResultTests.cs (1)
91var services = new ServiceCollection();
NotFoundOfTResultTests.cs (1)
150var services = new ServiceCollection();
NotFoundResultTests.cs (1)
99var services = new ServiceCollection();
OkOfTResultTests.cs (1)
158var services = new ServiceCollection();
OkResultTests.cs (1)
93var services = new ServiceCollection();
ProblemResultTests.cs (1)
252var services = new ServiceCollection();
PushStreamResultTests.cs (1)
19RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider()
RedirectToRouteResultTests.cs (1)
110var services = new ServiceCollection();
ResultsOfTTests.cs (1)
55var services = new ServiceCollection();
SignInResultTests.cs (1)
99var services = new ServiceCollection();
SignOutResultTests.cs (1)
98var services = new ServiceCollection();
src\Shared\ResultsTests\FileContentResultTestBase.cs (1)
355var services = new ServiceCollection();
src\Shared\ResultsTests\FileStreamResultTestBase.cs (1)
443var services = new ServiceCollection();
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
460var services = new ServiceCollection();
src\Shared\ResultsTests\RedirectResultTestBase.cs (1)
63var serviceCollection = new ServiceCollection();
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
487var services = new ServiceCollection();
StatusCodeResultTests.cs (1)
48var services = new ServiceCollection();
UnauthorizedResultTests.cs (1)
58var services = new ServiceCollection();
UnprocessableEntityOfTResultTests.cs (1)
158var services = new ServiceCollection();
UnprocessableEntityResultTests.cs (1)
94var services = new ServiceCollection();
Utf8ContentResultTests.cs (1)
90var services = new ServiceCollection();
ValidationProblemResultTests.cs (1)
178var services = new ServiceCollection();
Microsoft.AspNetCore.Http.Tests (7)
ApplicationBuilderTests.cs (2)
82var services = new ServiceCollection(); 108var services = new ServiceCollection();
DefaultHttpContextTests.cs (3)
191var serviceProvider = new ServiceCollection() 206var serviceProvider = new ServiceCollection() 233var serviceProvider = new AsyncDisposableServiceProvider(new ServiceCollection()
HttpServiceCollectionExtensionsTests.cs (1)
14var services = new ServiceCollection();
ResponseCookiesTest.cs (1)
29var services = new ServiceCollection();
Microsoft.AspNetCore.HttpLogging.Tests (5)
HttpLoggingServicesExtensionsTests.cs (5)
15new ServiceCollection().AddHttpLogging(null)); 22new ServiceCollection().AddW3CLogging(null)); 28var services = new ServiceCollection(); 40var services = new ServiceCollection(); 52var services = new ServiceCollection();
Microsoft.AspNetCore.HttpOverrides.Tests (2)
CertificateForwardingTest.cs (2)
20var services = new ServiceCollection() 30var services = new ServiceCollection()
Microsoft.AspNetCore.Identity.EntityFrameworkCore.Test (20)
CustomSchemaTest.cs (1)
19var services = new ServiceCollection();
DbUtil.cs (1)
21services = new ServiceCollection();
DefaultPocoTest.cs (1)
20var services = new ServiceCollection();
EmptySchemaTest.cs (1)
19var services = new ServiceCollection();
MaxKeyLengthSchemaTest.cs (1)
20var services = new ServiceCollection();
SqlStoreTestBase.cs (1)
95var services = new ServiceCollection();
UserOnlyCustomContextTest.cs (1)
64var services = new ServiceCollection();
UserOnlyTest.cs (1)
25var services = new ServiceCollection();
UserStoreEncryptPersonalDataTest.cs (2)
182var services = new ServiceCollection().AddLogging(); 279var services = new ServiceCollection().AddLogging();
UserStoreGuidKeyTest.cs (2)
57var services = new ServiceCollection(); 74var services = new ServiceCollection();
UserStoreIntKeyTest.cs (2)
35var services = new ServiceCollection(); 52var services = new ServiceCollection();
UserStoreStringKeyTest.cs (2)
36var services = new ServiceCollection(); 53var services = new ServiceCollection();
UserStoreWithGenericsTest.cs (2)
81var services = new ServiceCollection(); 90var services = new ServiceCollection();
VersionOneSchemaTest.cs (1)
19var services = new ServiceCollection();
VersionTwoSchemaTest.cs (1)
19var services = new ServiceCollection();
Microsoft.AspNetCore.Identity.InMemory.Test (3)
ControllerTest.cs (3)
31var services = new ServiceCollection() 83var services = new ServiceCollection() 111context.RequestServices = new ServiceCollection().AddSingleton(auth.Object).BuildServiceProvider();
Microsoft.AspNetCore.Identity.Specification.Tests (2)
IdentitySpecificationTestBase.cs (1)
84services = new ServiceCollection();
UserManagerSpecificationTests.cs (1)
82services = new ServiceCollection();
Microsoft.AspNetCore.Identity.Test (38)
IdentityBuilderTest.cs (20)
16var services = new ServiceCollection(); 32Assert.Throws<ArgumentException>(() => new IdentityBuilder(typeof(int), new ServiceCollection())); 38Assert.Throws<ArgumentException>(() => new IdentityBuilder(typeof(PocoUser), typeof(int), new ServiceCollection())); 44var services = new ServiceCollection(); 56var services = new ServiceCollection() 66var services = new ServiceCollection() 76var services = new ServiceCollection() 91var services = new ServiceCollection() 107var services = new ServiceCollection() 117var services = new ServiceCollection() 127var services = new ServiceCollection() 137var services = new ServiceCollection() 149var services = new ServiceCollection() 161var services = new ServiceCollection() 178var services = new ServiceCollection() 202var services = new ServiceCollection() 221var services = new ServiceCollection() 241var services = new ServiceCollection() 253var services = new ServiceCollection() 264var services = new ServiceCollection()
IdentityOptionsTest.cs (3)
40var services = new ServiceCollection().Configure<IdentityOptions>(options => options.Password.RequiredLength = -1); 60var services = new ServiceCollection(); 74var services = new ServiceCollection();
SecurityStampValidatorTest.cs (7)
61httpContext.Setup(c => c.RequestServices).Returns(new ServiceCollection().BuildServiceProvider()); 119var services = new ServiceCollection(); 173var services = new ServiceCollection(); 214var services = new ServiceCollection(); 252var services = new ServiceCollection(); 290var services = new ServiceCollection(); 339var services = new ServiceCollection();
SignInManagerTest.cs (1)
808context.RequestServices = new ServiceCollection().AddSingleton(auth.Object).BuildServiceProvider();
UserManagerTest.cs (7)
18var services = new ServiceCollection() 33var services = new ServiceCollection() 792var services = new ServiceCollection() 807var services = new ServiceCollection() 818var services = new ServiceCollection() 889var services = new ServiceCollection() 1745var services = new ServiceCollection()
Microsoft.AspNetCore.InternalTesting (2)
AssemblyTestLog.cs (2)
163var serviceCollection = new ServiceCollection(); 195var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.InternalTesting.Tests (2)
LoggedTestXunitTests.cs (1)
109var serviceCollection = new ServiceCollection();
XunitLoggerProviderTest.cs (1)
88return new ServiceCollection()
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (1)
EndpointMetadataApiDescriptionProviderTest.cs (1)
1533var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Core.Test (110)
AcceptedAtActionResultTests.cs (1)
270var services = new ServiceCollection();
AcceptedAtRouteResultTests.cs (1)
178var services = new ServiceCollection();
AcceptedResultTests.cs (1)
135var services = new ServiceCollection();
ActionConstraints\ActionConstraintCacheTest.cs (1)
154return new ServiceCollection().BuildServiceProvider();
ApplicationModels\EndpointMetadataProviderTest.cs (1)
267var services = new ServiceCollection();
Authorization\AuthorizeFilterTest.cs (6)
429var result = factory.CreateInstance(new ServiceCollection().BuildServiceProvider()); 445var result = factory.CreateInstance(new ServiceCollection().BuildServiceProvider()); 469var serviceProvider = new ServiceCollection() 497var serviceProvider = new ServiceCollection() 552ActionContext.HttpContext.RequestServices = new ServiceCollection() 598var serviceCollection = new ServiceCollection();
Builder\MvcApplicationBuilderExtensionsTest.cs (2)
38var services = new ServiceCollection(); 63var services = new ServiceCollection();
Builder\MvcAreaRouteBuilderExtensionsTest.cs (1)
271var services = new ServiceCollection();
ChallengeResultTest.cs (1)
70var services = new ServiceCollection();
ContentResultTest.cs (1)
266var services = new ServiceCollection();
ControllerBaseTest.cs (1)
3197var services = new ServiceCollection();
Controllers\ControllerActivatorProviderTest.cs (1)
49var serviceProvider = new ServiceCollection()
Controllers\ControllerBinderDelegateProviderTest.cs (1)
1251var services = new ServiceCollection();
CreatedAtActionResultTests.cs (1)
90var services = new ServiceCollection();
CreatedAtRouteResultTests.cs (1)
104var services = new ServiceCollection();
CreatedResultTests.cs (1)
137var services = new ServiceCollection();
DependencyInjection\MvcBuilderExtensionsTest.cs (3)
83var collection = new ServiceCollection(); 115var services = new ServiceCollection(); 137var serviceCollection = new ServiceCollection()
DependencyInjection\MvcCoreBuilderExtensionsTest.cs (1)
80var serviceCollection = new ServiceCollection()
DependencyInjection\MvcCoreServiceCollectionExtensionsTest.cs (9)
34var services = new ServiceCollection(); 62var services = new ServiceCollection(); 85var services = new ServiceCollection(); 113var services = new ServiceCollection(); 131var services = new ServiceCollection(); 150var services = new ServiceCollection(); 171var services = new ServiceCollection(); 194var services = new ServiceCollection(); 218var services = new ServiceCollection();
FileContentResultTest.cs (1)
33httpContext.RequestServices = new ServiceCollection()
FileResultHelperTest.cs (3)
78var provider = new ServiceCollection() 125httpContext.RequestServices = new ServiceCollection().BuildServiceProvider(); 462var services = new ServiceCollection();
FileStreamResultTest.cs (1)
24httpContext.RequestServices = new ServiceCollection()
Filters\MiddlewareFilterAttributeTest.cs (1)
16var services = new ServiceCollection();
Filters\MiddlewareFilterBuilderTest.cs (6)
21var services = new ServiceCollection(); 46var services = new ServiceCollection(); 79var services = new ServiceCollection(); 108var services = new ServiceCollection(); 160var services = new ServiceCollection(); 228var services = new ServiceCollection();
Filters\MiddlewareFilterConfigurationProviderTest.cs (2)
48var services = new ServiceCollection(); 97services = new ServiceCollection();
Filters\MiddlewareFilterTest.cs (2)
321var applicationServices = new ServiceCollection(); 334var services = new ServiceCollection();
ForbidResultTest.cs (1)
141return new ServiceCollection()
Formatters\TextOutputFormatterTests.cs (1)
219new DefaultHttpContext() { RequestServices = new ServiceCollection().BuildServiceProvider() },
HttpActionResultTests.cs (1)
53var services = new ServiceCollection();
HttpNotFoundObjectResultTest.cs (1)
70var services = new ServiceCollection();
HttpOkObjectResultTest.cs (1)
72var services = new ServiceCollection();
HttpOkResultTest.cs (1)
44var services = new ServiceCollection();
HttpStatusCodeResultTests.cs (1)
50var services = new ServiceCollection();
Infrastructure\ActionSelectorTest.cs (1)
1102var serviceProvider = new ServiceCollection().BuildServiceProvider();
Infrastructure\ControllerActionInvokerTest.cs (1)
1707var services = new ServiceCollection();
Infrastructure\DefaultApiProblemDetailsWriterTest.cs (1)
217var services = new ServiceCollection();
Infrastructure\JsonResultExecutorTestBase.cs (1)
483var services = new ServiceCollection();
Infrastructure\ObjectResultExecutorTest.cs (1)
460var services = new ServiceCollection();
LocalRedirectResultTest.cs (1)
138var serviceCollection = new ServiceCollection();
ModelBinding\Binders\BinderTypeModelBinderTest.cs (2)
35var serviceProvider = new ServiceCollection() 77HttpContext = new DefaultHttpContext() { RequestServices = new ServiceCollection().BuildServiceProvider() },
ModelBinding\Binders\ComplexObjectModelBinderTest.cs (2)
470RequestServices = new ServiceCollection().BuildServiceProvider(), 497RequestServices = new ServiceCollection().BuildServiceProvider(),
ModelBinding\Binders\ComplexTypeModelBinderTest.cs (2)
651RequestServices = new ServiceCollection().BuildServiceProvider(), 678RequestServices = new ServiceCollection().BuildServiceProvider(),
ModelBinding\Binders\HeaderModelBinderTests.cs (1)
341var services = new ServiceCollection();
ModelBinding\Binders\ServicesModelBinderTest.cs (1)
39var services = new ServiceCollection();
ModelBinding\DefaultModelBindingContextTest.cs (1)
157var services = new ServiceCollection();
ModelBinding\ModelBinderFactoryTest.cs (1)
641var services = new ServiceCollection();
ModelBinding\ModelBindingHelperTest.cs (1)
1495var services = new ServiceCollection();
ModelBinding\ParameterBinderTest.cs (1)
706var services = new ServiceCollection();
ModelBinding\TestModelBinderProviderContext.cs (1)
99var services = new ServiceCollection();
ModelBinding\Validation\DefaultObjectValidatorTests.cs (1)
582var provider = new ServiceCollection().AddSingleton(service.Object).BuildServiceProvider();
ObjectResultTests.cs (1)
158var services = new ServiceCollection();
PhysicalFileResultTest.cs (1)
58var services = new ServiceCollection();
RedirectResultTest.cs (1)
27var serviceCollection = new ServiceCollection();
RedirectToActionResultTest.cs (1)
149var services = new ServiceCollection();
RedirectToPageResultTest.cs (1)
294var services = new ServiceCollection();
RedirectToRouteResultTest.cs (1)
177var services = new ServiceCollection();
RequireHttpsAttributeTests.cs (1)
239var services = new ServiceCollection();
Routing\ActionEndpointDataSourceBaseTest.cs (1)
137var services = new ServiceCollection();
Routing\ActionEndpointFactoryTest.cs (1)
19var serviceCollection = new ServiceCollection();
Routing\AttributeRouteTest.cs (2)
766var services = new ServiceCollection() 808var services = new ServiceCollection()
Routing\AttributeRoutingTest.cs (1)
173var services = new ServiceCollection()
Routing\ControllerLinkGeneratorExtensionsTest.cs (1)
214var services = new ServiceCollection();
Routing\DynamicControllerEndpointMatcherPolicyTest.cs (2)
66var services = new ServiceCollection(); 229RequestServices = new ServiceCollection().AddScoped(sp => new CustomTransformer { State = "Invalid" }).BuildServiceProvider(),
Routing\KnownRouteValueConstraintTests.cs (1)
29var services = new ServiceCollection();
Routing\PageLinkGeneratorExtensionsTest.cs (1)
184var services = new ServiceCollection();
Routing\UrlHelperBaseTest.cs (1)
104var services = new ServiceCollection();
Routing\UrlHelperTestBase.cs (1)
1160var services = new ServiceCollection();
ServiceFilterAttributeTest.cs (2)
16var serviceProvider = new ServiceCollection() 33var serviceProvider = new ServiceCollection()
SignInResultTest.cs (1)
102return new ServiceCollection()
SignOutResultTest.cs (1)
167return new ServiceCollection()
src\Shared\ResultsTests\FileContentResultTestBase.cs (1)
355var services = new ServiceCollection();
src\Shared\ResultsTests\FileStreamResultTestBase.cs (1)
443var services = new ServiceCollection();
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
460var services = new ServiceCollection();
src\Shared\ResultsTests\RedirectResultTestBase.cs (1)
63var serviceCollection = new ServiceCollection();
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
487var services = new ServiceCollection();
TypeFilterAttributeTest.cs (3)
17var serviceProvider = new ServiceCollection() 39var serviceProvider = new ServiceCollection() 64var serviceProvider = new ServiceCollection()
VirtualFileResultTest.cs (1)
84httpContext.RequestServices = new ServiceCollection()
Microsoft.AspNetCore.Mvc.Core.TestCommon (1)
TestModelBinderFactory.cs (1)
82var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Cors.Test (1)
CorsAuthorizationFilterTest.cs (1)
144var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (2)
DataAnnotationsModelValidatorTest.cs (1)
402var provider = new ServiceCollection().AddSingleton(service.Object).BuildServiceProvider();
MvcDataAnnotationsMvcOptionsSetup.cs (1)
17var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Formatters.Xml.Test (2)
XmlDataContractSerializerOutputFormatterTest.cs (1)
807httpContext.RequestServices = new ServiceCollection()
XmlSerializerOutputFormatterTest.cs (1)
589httpContext.RequestServices = new ServiceCollection()
Microsoft.AspNetCore.Mvc.IntegrationTests (4)
AuthorizeFilterIntegrationTest.cs (1)
178var serviceCollection = new ServiceCollection();
HasValidatorsValidationMetadataProviderIntegrationTest.cs (2)
19var serviceCollection = new ServiceCollection(); 34var serviceCollection = new ServiceCollection();
ModelBindingTestHelper.cs (1)
167var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Localization.Test (4)
MvcLocalizationMvcBuilderExtensionsTest.cs (1)
139_services = new ServiceCollection();
MvcLocalizationMvcCoreBuilderExtensionsTest.cs (1)
139_services = new ServiceCollection();
MvcLocalizationServiceCollectionExtensionsTest.cs (2)
18var collection = new ServiceCollection(); 35var collection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.NewtonsoftJson.Test (11)
DependencyInjection\NewtonsoftJsonMvcBuilderExtensionsTest.cs (1)
16var services = new ServiceCollection();
DependencyInjection\NewtonsoftJsonMvcCoreBuilderExtensionsTest.cs (4)
20var services = new ServiceCollection(); 37var services = new ServiceCollection() 52var services = new ServiceCollection() 67var services = new ServiceCollection()
JsonResultTest.cs (1)
51var services = new ServiceCollection();
NewtonsoftJsonOutputFormatterTest.cs (4)
59var services = new ServiceCollection() 445actionContext.HttpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider(); 490actionContext.HttpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider(); 524actionContext.HttpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider();
src\Mvc\Mvc.Core\test\Infrastructure\JsonResultExecutorTestBase.cs (1)
483var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation.Test (3)
DependencyInjection\RazorRuntimeCompilationMvcCoreBuilderExtensionsTest.cs (2)
18var services = new ServiceCollection() 33var services = new ServiceCollection()
PageLoaderMatcherPolicyTest.cs (1)
49RequestServices = new ServiceCollection().AddSingleton(loader.Object).BuildServiceProvider(),
Microsoft.AspNetCore.Mvc.Razor.Test (20)
DefaultTagHelperFactoryTest.cs (4)
26var services = new ServiceCollection(); 53var services = new ServiceCollection(); 71var services = new ServiceCollection(); 99var services = new ServiceCollection();
DependencyInjection\MvcRazorMvcBuilderExtensionsTest.cs (2)
17var services = new ServiceCollection(); 36var services = new ServiceCollection();
DependencyInjection\MvcRazorMvcCoreBuilderExtensionsTest.cs (4)
19var services = new ServiceCollection(); 35var services = new ServiceCollection(); 56var services = new ServiceCollection(); 76var services = new ServiceCollection();
Infrastructure\DefaultTagHelperActivatorTest.cs (1)
25RequestServices = new ServiceCollection().BuildServiceProvider()
RazorHotReloadTest.cs (1)
75var serviceProvider = new ServiceCollection()
RazorPageActivatorTest.cs (1)
249var serviceProvider = new ServiceCollection()
RazorPageCreateModelExpressionTest.cs (1)
315var serviceCollection = new ServiceCollection();
RazorPageTest.cs (1)
1415var serviceProvider = new ServiceCollection()
RazorViewEngineOptionsTest.cs (2)
16var services = new ServiceCollection().AddOptions(); 47var services = new ServiceCollection().AddOptions();
RazorViewTest.cs (1)
1789var serviceProvider = new ServiceCollection()
TagHelpers\TagHelperComponentPropertyActivatorTest.cs (1)
52RequestServices = new ServiceCollection()
TagHelpers\TagHelperComponentTagHelperTest.cs (1)
390RequestServices = new ServiceCollection()
Microsoft.AspNetCore.Mvc.RazorPages.Test (15)
Builder\PageActionEndpointConventionBuilderResourceCollectionExtensionsTest.cs (1)
215var collection = new ServiceCollection();
DependencyInjection\MvcRazorPagesMvcBuilderExtensionsTest.cs (1)
18var services = new ServiceCollection().AddOptions()
DependencyInjection\PageConventionCollectionExtensionsTest.cs (1)
979var serviceProvider = new ServiceCollection()
Filters\PageSaveTempDataPropertyFilterFactoryTest.cs (1)
33var serviceCollection = new ServiceCollection();
Infrastructure\DefaultPageFactoryProviderTest.cs (3)
250var serviceProvider = new ServiceCollection() 293var serviceProvider = new ServiceCollection() 331var serviceProvider = new ServiceCollection()
Infrastructure\DefaultPageModelActivatorProviderTest.cs (2)
39var serviceCollection = new ServiceCollection(); 69var serviceCollection = new ServiceCollection();
Infrastructure\DynamicPageEndpointMatcherPolicyTest.cs (2)
57var services = new ServiceCollection(); 290RequestServices = new ServiceCollection().AddScoped(sp => new CustomTransformer() { State = "Invalid" }).BuildServiceProvider()
Infrastructure\PageActionInvokerTest.cs (1)
1500var services = new ServiceCollection();
Infrastructure\PageBinderFactoryTest.cs (1)
785var services = new ServiceCollection();
PageModelTest.cs (1)
1789httpContext.RequestServices = new ServiceCollection()
src\Mvc\Mvc.Core\test\Routing\ActionEndpointDataSourceBaseTest.cs (1)
137var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.TagHelpers.Test (3)
ComponentTagHelperTest.cs (1)
85RequestServices = new ServiceCollection()
DefaultTagHelperActivatorTest.cs (1)
56var services = new ServiceCollection()
PersistComponentStateTagHelperTest.cs (1)
259RequestServices = new ServiceCollection()
Microsoft.AspNetCore.Mvc.Test (19)
MvcOptionsSetupTest.cs (1)
286var serviceCollection = new ServiceCollection();
MvcServiceCollectionExtensionsTest.cs (18)
48var services = new ServiceCollection(); 86var services = new ServiceCollection(); 101var services = new ServiceCollection(); 117var services = new ServiceCollection(); 132var services = new ServiceCollection(); 165var services = new ServiceCollection(); 182var services = new ServiceCollection(); 201var services = new ServiceCollection(); 218var services = new ServiceCollection(); 235var services = new ServiceCollection(); 299var services = new ServiceCollection(); 326var services = new ServiceCollection(); 352var services = new ServiceCollection(); 380var services = new ServiceCollection(); 396var services = new ServiceCollection(); 430var services = new ServiceCollection(); 444var services = new ServiceCollection(); 459var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (28)
Builder\ControllerActionEndpointConventionBuilderResourceCollectionExtensionsTest.cs (1)
288var collection = new ServiceCollection();
DependencyInjection\MvcViewFeaturesMvcBuilderExtensionsTest.cs (2)
127var services = new ServiceCollection(); 160var services = new ServiceCollection();
DependencyInjection\MvcViewFeaturesMvcCoreBuilderExtensionsTest.cs (11)
16var services = new ServiceCollection(); 31var services = new ServiceCollection(); 46var services = new ServiceCollection(); 62var services = new ServiceCollection(); 77var services = new ServiceCollection(); 93var services = new ServiceCollection(); 109var services = new ServiceCollection(); 125var services = new ServiceCollection(); 141var services = new ServiceCollection(); 157var services = new ServiceCollection(); 173var services = new ServiceCollection();
Filters\ControllerSaveTempDataPropertyFilterFactoryTest.cs (1)
29var serviceCollection = new ServiceCollection();
PageRemoteAttributeTest.cs (5)
45ActionContext = GetActionContext(new ServiceCollection().BuildServiceProvider(), routeData) 83ActionContext = GetActionContext(new ServiceCollection().BuildServiceProvider(), routeData) 115ActionContext = GetActionContext(new ServiceCollection().BuildServiceProvider(), routeData) 146ActionContext = GetActionContext(new ServiceCollection().BuildServiceProvider(), routeData) 185var serviceCollection = new ServiceCollection();
PartialViewResultTest.cs (1)
244var services = new ServiceCollection();
RemoteAttributeBaseTest.cs (1)
468var serviceCollection = new ServiceCollection();
RemoteAttributeTest.cs (1)
486var serviceCollection = new ServiceCollection();
Rendering\DefaultTemplatesUtilities.cs (1)
269var serviceProvider = new ServiceCollection()
ViewComponentResultTest.cs (1)
661var services = new ServiceCollection();
ViewComponents\ViewViewComponentResultTest.cs (1)
427var serviceProvider = new ServiceCollection().BuildServiceProvider();
ViewExecutorTest.cs (1)
162var serviceCollection = new ServiceCollection();
ViewResultTest.cs (1)
256var services = new ServiceCollection();
Microsoft.AspNetCore.OpenApi.Tests (47)
Extensions\OpenApiEndpointRouteBuilderExtensionsTests.cs (1)
184var serviceProvider = new ServiceCollection()
Extensions\OpenApiRouteHandlerBuilderExtensionTests.cs (7)
21var serviceProvider = new ServiceCollection() 44var serviceProvider = new ServiceCollection() 67var serviceProvider = new ServiceCollection() 95var serviceProvider = new ServiceCollection() 124var serviceProvider = new ServiceCollection() 156var serviceProvider = new ServiceCollection() 186var serviceProvider = new ServiceCollection()
Extensions\OpenApiServiceCollectionExtensionsTests.cs (10)
16var services = new ServiceCollection(); 30var services = new ServiceCollection(); 50var services = new ServiceCollection(); 64var services = new ServiceCollection(); 84var services = new ServiceCollection(); 97var services = new ServiceCollection(); 117var services = new ServiceCollection(); 130var services = new ServiceCollection(); 150var services = new ServiceCollection(); 174var services = new ServiceCollection();
Services\OpenApiDocumentProviderTests.cs (1)
63var serviceCollection = new ServiceCollection()
Services\OpenApiDocumentServiceTestsBase.cs (1)
163serviceProvider.SetInternalServiceProvider(serviceCollection ?? new ServiceCollection());
Services\OpenApiSchemaService\OpenApiSchemaService.ParameterSchemas.cs (1)
539var serviceCollection = new ServiceCollection();
Services\OpenApiSchemaService\OpenApiSchemaService.RequestBodySchemas.cs (1)
491var serviceCollection = new ServiceCollection();
Transformers\DocumentTransformerTests.cs (5)
76var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 102var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 166var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 194var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 221var serviceCollection = new ServiceCollection().AddTransient<Dependency>();
Transformers\Implementations\OpenApiSchemaReferenceTransformerTests.cs (1)
426var serviceCollection = new ServiceCollection();
Transformers\OperationTransformerTests.cs (5)
272var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 322var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 404var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 431var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 458var serviceCollection = new ServiceCollection().AddTransient<Dependency>();
Transformers\SchemaTransformerTests.cs (5)
282var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 320var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 761var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 788var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 815var serviceCollection = new ServiceCollection().AddTransient<Dependency>();
Transformers\TypeBasedTransformerLifetimeTests.cs (9)
36var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 62var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 88var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 135var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 160var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 186var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 255var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 281var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 307var serviceCollection = new ServiceCollection().AddTransient<Dependency>();
Microsoft.AspNetCore.Owin.Tests (3)
OwinExtensionTests.cs (3)
41new ServiceCollection().AddSingleton(new FakeService()).BuildServiceProvider()); 58IServiceProvider expectedServiceProvider = new ServiceCollection().BuildServiceProvider(); 124var serviceProvider = new ServiceCollection().BuildServiceProvider();
Microsoft.AspNetCore.RateLimiting.Tests (6)
RateLimitingApplicationBuilderExtensionsTests.cs (4)
22var appBuilder = new ApplicationBuilder(new ServiceCollection().BuildServiceProvider()); 29var services = new ServiceCollection(); 47var services = new ServiceCollection(); 68var services = new ServiceCollection();
RateLimitingMetricsTests.cs (2)
175var services = new ServiceCollection(); 250var services = new ServiceCollection();
Microsoft.AspNetCore.RequestDecompression.Tests (1)
RequestDecompressionServiceExtensionsTests.cs (1)
28var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.ResponseCompression.Microbenchmarks (1)
ResponseCompressionProviderBenchmark.cs (1)
17var services = new ServiceCollection()
Microsoft.AspNetCore.Routing.Microbenchmarks (1)
EndpointRoutingBenchmarkBase.cs (1)
29var services = new ServiceCollection();
Microsoft.AspNetCore.Routing.Tests (69)
Builder\EndpointRoutingApplicationBuilderExtensionsTest.cs (1)
351var services = new ServiceCollection();
Builder\RouteHandlerEndpointRouteBuilderExtensionsTest.cs (18)
263var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 283var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 303var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 327var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 347var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 367var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().AddSingleton<TodoService>().BuildServiceProvider())); 638httpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider(); 821httpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider(); 839var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 848httpContext.RequestServices = new ServiceCollection().AddLogging().BuildServiceProvider(); 896httpContext.RequestServices = new ServiceCollection().BuildServiceProvider(); 917var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 933var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 961var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 972var serviceCollection = new ServiceCollection(); 990var appServiceCollection = new ServiceCollection(); 1016var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 1038var builder = new DefaultEndpointRouteBuilder(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider()));
Builder\RoutingBuilderExtensionsTest.cs (1)
124var services = new ServiceCollection();
CompositeEndpointDataSourceTest.cs (6)
46var applicationServices = new ServiceCollection().BuildServiceProvider(); 74ApplicationServices = new ServiceCollection().BuildServiceProvider(), 289var applicationServices = new ServiceCollection().BuildServiceProvider(); 329var applicationServices = new ServiceCollection().BuildServiceProvider(); 381var applicationServices = new ServiceCollection().BuildServiceProvider(); 440var applicationServices = new ServiceCollection().BuildServiceProvider();
DefaultParameterPolicyFactoryTest.cs (12)
38var services = new ServiceCollection(); 198var services = new ServiceCollection(); 217var services = new ServiceCollection(); 238var services = new ServiceCollection(); 261var services = new ServiceCollection(); 282var services = new ServiceCollection(); 303var services = new ServiceCollection(); 325var services = new ServiceCollection(); 346var services = new ServiceCollection(); 367var services = new ServiceCollection(); 387var services = new ServiceCollection(); 410services = new ServiceCollection();
EndpointRoutingMiddlewareFormOptionsTest.cs (1)
96var serviceProvider = new ServiceCollection().Configure<FormOptions>(options =>
EndpointRoutingMiddlewareTest.cs (1)
403var services = new ServiceCollection();
InlineRouteParameterParserTests.cs (1)
959var services = new ServiceCollection().AddOptions();
Internal\DfaGraphWriterTest.cs (1)
14ServiceCollection services = new ServiceCollection();
LinkGeneratorTestBase.cs (1)
23var services = new ServiceCollection();
LinkParserTestBase.cs (1)
15var services = new ServiceCollection();
Matching\DfaMatcherBuilderTest.cs (1)
3542var serviceCollection = new ServiceCollection();
Matching\DfaMatcherConformanceTest.cs (1)
64var services = new ServiceCollection()
Matching\DfaMatcherTest.cs (1)
29var serviceCollection = new ServiceCollection()
Matching\HostMatcherPolicyIntegrationTestBase.cs (1)
369var services = new ServiceCollection()
Matching\HttpMethodMatcherPolicyIntegrationTestBase.cs (1)
348var services = new ServiceCollection()
Matching\MatcherConformanceTest.cs (1)
26var services = new ServiceCollection();
Patterns\DefaultRoutePatternTransformerTest.cs (1)
13var services = new ServiceCollection();
RequestDelegateRouteBuilderExtensionsTest.cs (1)
125var services = new ServiceCollection();
RouteBuilderTest.cs (1)
16var services = new ServiceCollection();
RouteCollectionTest.cs (2)
600var services = new ServiceCollection(); 620var services = new ServiceCollection();
RouteHandlerOptionsTests.cs (3)
20var services = new ServiceCollection(); 36var services = new ServiceCollection(); 60var services = new ServiceCollection();
RouteOptionsTests.cs (2)
16var services = new ServiceCollection(); 32var services = new ServiceCollection();
RouterMiddlewareTest.cs (1)
20var services = new ServiceCollection();
RouteTest.cs (3)
653var services = new ServiceCollection(); 1515var services = new ServiceCollection(); 1760var services = new ServiceCollection();
RoutingServiceCollectionExtensionsTests.cs (2)
31var services = new ServiceCollection(); 66var services = new ServiceCollection();
TemplateParserDefaultValuesTests.cs (2)
128var services = new ServiceCollection(); 146var services = new ServiceCollection().AddOptions();
Tree\TreeRouteBuilderTest.cs (1)
257var services = new ServiceCollection().AddOptions();
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (7)
AddressBinderTests.cs (1)
293var services = new ServiceCollection();
KestrelServerOptionsTests.cs (2)
71ApplicationServices = new ServiceCollection().BuildServiceProvider() 83var serviceCollection = new ServiceCollection();
KestrelServerTests.cs (3)
37serverOptions.ApplicationServices = new ServiceCollection() 788var serviceCollection = new ServiceCollection(); 927var serviceCollection = new ServiceCollection();
ListenOptionsTests.cs (1)
26var serviceProvider = new ServiceCollection().BuildServiceProvider();
Microsoft.AspNetCore.Server.Kestrel.Tests (1)
KestrelConfigurationLoaderTests.cs (1)
27serverOptions.ApplicationServices = new ServiceCollection()
Microsoft.AspNetCore.SignalR.Client.Core (1)
HubConnectionBuilder.cs (1)
29Services = new ServiceCollection();
Microsoft.AspNetCore.SignalR.Microbenchmarks (2)
DefaultHubActivatorBenchmark.cs (1)
17var services = new ServiceCollection();
DefaultHubDispatcherBenchmark.cs (1)
25var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (1)
RedisDependencyInjectionExtensionsTests.cs (1)
23var services = new ServiceCollection();
Microsoft.AspNetCore.SignalR.Tests (8)
AddSignalRTests.cs (7)
25var serviceCollection = new ServiceCollection(); 54var serviceCollection = new ServiceCollection(); 77var serviceCollection = new ServiceCollection(); 96var serviceCollection = new ServiceCollection(); 122var serviceCollection = new ServiceCollection(); 136var serviceCollection = new ServiceCollection(); 172var serviceCollection = new ServiceCollection();
HubConnectionHandlerTestUtils\Utils.cs (1)
58var services = new ServiceCollection();
Microsoft.AspNetCore.SpaServices.Extensions.Tests (1)
SpaServicesExtensionsTests.cs (1)
58var services = new ServiceCollection();
Microsoft.AspNetCore.TestHost.Tests (4)
TestServerTests.cs (4)
313var serviceProvider = new ServiceCollection().BuildServiceProvider(); 403var services = new ServiceCollection(); 451context.RequestServices = new ServiceCollection() 495var appServices = new ServiceCollection().BuildServiceProvider();
Microsoft.AspNetCore.Testing.Tests (2)
FakeStartupTests.cs (2)
20sut.Configure(new ApplicationBuilder(new ServiceCollection().BuildServiceProvider())); 22sut.ConfigureServices(new ServiceCollection());
Microsoft.AspNetCore.WebSockets.Tests (1)
AddWebSocketsTests.cs (1)
15var serviceCollection = new ServiceCollection();
Microsoft.DotNet.Build.Tasks.Feed.Tests (13)
BuildModelFactoryTests.cs (1)
52ServiceProvider provider = new ServiceCollection()
GenerateBuildManifestTests.cs (2)
24var collection = new ServiceCollection(); 61var collection = new ServiceCollection()
PublishArtifactsInManifestTests.cs (2)
47var collection = new ServiceCollection() 266var collection = new ServiceCollection();
PushToBuildStorageTests.cs (8)
213var collection = new ServiceCollection() 244var collection = new ServiceCollection() 289var collection = new ServiceCollection() 338var collection = new ServiceCollection() 385var collection = new ServiceCollection() 435var collection = new ServiceCollection() 539var collection = new ServiceCollection() 561var collection = new ServiceCollection();
Microsoft.DotNet.Helix.Sdk.Tests (9)
CreateXHarnessAndroidWorkItemsTests.cs (2)
203var collection = new ServiceCollection(); 255var collection = new ServiceCollection();
CreateXHarnessAppleWorkItemsTests.cs (2)
262var collection = new ServiceCollection(); 328var collection = new ServiceCollection();
FindDotNetCliPackageTests.cs (1)
225var collection = new ServiceCollection();
InstallDotNetToolTests.cs (4)
242var collection1 = new ServiceCollection(); 247var collection2 = new ServiceCollection(); 321var collection = new ServiceCollection(); 339var collection = new ServiceCollection();
Microsoft.DotNet.Internal.DependencyInjection.Testing (1)
DependencyInjectionValidation.cs (1)
44var services = new ServiceCollection();
Microsoft.DotNet.VersionTools.Tasks.Tests (2)
LocalUpdatePublishedVersionsTests.cs (1)
19var collection = new ServiceCollection();
UpdatePublishedVersionsTests.cs (1)
19var collection = new ServiceCollection();
Microsoft.Extensions.AI.Tests (8)
ChatCompletion\ChatClientBuilderTest.cs (1)
15var expectedServiceProvider = new ServiceCollection().BuildServiceProvider();
ChatCompletion\DependencyInjectionPatterns.cs (1)
12private IServiceCollection ServiceCollection { get; } = new ServiceCollection();
ChatCompletion\DistributedCachingChatClientTest.cs (1)
673var services = new ServiceCollection()
ChatCompletion\FunctionInvokingChatClientTests.cs (1)
418ServiceCollection c = new();
ChatCompletion\LoggingChatClientTests.cs (1)
32ServiceCollection c = new();
Embeddings\DistributedCachingEmbeddingGeneratorTest.cs (1)
314var services = new ServiceCollection()
Embeddings\EmbeddingGeneratorBuilderTests.cs (1)
15var expectedServiceProvider = new ServiceCollection().BuildServiceProvider();
Embeddings\LoggingEmbeddingGeneratorTests.cs (1)
31ServiceCollection c = new();
Microsoft.Extensions.AmbientMetadata.Application.Tests (3)
ApplicationMetadataExtensionsTests.cs (3)
35var serviceCollection = new ServiceCollection(); 110using var provider = new ServiceCollection() 130using var provider = new ServiceCollection()
Microsoft.Extensions.AsyncState.Tests (2)
AsyncContextServiceCollectionExtensionsTests.cs (1)
23var services = new ServiceCollection();
AsyncStateTests.cs (1)
257var services = new ServiceCollection().AddAsyncState().BuildServiceProvider();
Microsoft.Extensions.Caching.Hybrid.Tests (26)
BufferReleaseTests.cs (1)
19var services = new ServiceCollection();
DistributedCacheTests.cs (1)
46var services = new ServiceCollection();
FunctionalTests.cs (1)
13var services = new ServiceCollection();
L2Tests.cs (1)
36var services = new ServiceCollection();
RedisTests.cs (1)
45var services = new ServiceCollection();
SampleUsage.cs (4)
16var services = new ServiceCollection(); 36var services = new ServiceCollection(); 56var services = new ServiceCollection(); 76var services = new ServiceCollection();
ServiceConstructionTests.cs (10)
28var services = new ServiceCollection(); 37var services = new ServiceCollection(); 89var services = new ServiceCollection(); 102var services = new ServiceCollection(); 115var services = new ServiceCollection(); 129var services = new ServiceCollection(); 141var services = new ServiceCollection(); 155var services = new ServiceCollection(); 175var services = new ServiceCollection(); 189var services = new ServiceCollection();
SizeTests.cs (4)
32var services = new ServiceCollection(); 101var services = new ServiceCollection(); 154var services = new ServiceCollection(); 216var services = new ServiceCollection();
StampedeTests.cs (1)
17var services = new ServiceCollection();
UnreliableL2Tests.cs (2)
126var services = new ServiceCollection(); 134services = new ServiceCollection();
Microsoft.Extensions.Caching.MicroBenchmarks (2)
DistributedCacheBenchmarks.cs (2)
51var services = new ServiceCollection(); 61services = new ServiceCollection();
Microsoft.Extensions.Caching.SqlServer.Tests (3)
SqlServerCacheServicesExtensionsTest.cs (3)
18var services = new ServiceCollection(); 34var services = new ServiceCollection(); 58var services = new ServiceCollection();
Microsoft.Extensions.Caching.StackExchangeRedis.Tests (6)
CacheServiceExtensionsTests.cs (6)
20var services = new ServiceCollection(); 36var services = new ServiceCollection(); 55var services = new ServiceCollection(); 64var services = new ServiceCollection(); 80var services = new ServiceCollection(); 97var services = new ServiceCollection();
Microsoft.Extensions.Compliance.Redaction.Tests (9)
HmacRedactorExtensionsTests.cs (2)
16using var serviceProvider = new ServiceCollection() 29using var serviceProvider = new ServiceCollection()
HmacRedactorTest.cs (2)
95var redactorProvider = new ServiceCollection() 123var redactorProvider = new ServiceCollection()
RedactionAcceptanceTests.cs (4)
20using var services = new ServiceCollection() 43using var services = new ServiceCollection() 57Assert.Throws<ArgumentNullException>(() => new ServiceCollection().AddRedaction(null!)); 63using var serviceProvider = new ServiceCollection()
RedactorProviderTests.cs (1)
78var redactorProvider = new ServiceCollection()
Microsoft.Extensions.Compliance.Testing.Tests (14)
RedactionFakesAcceptanceTests.cs (13)
20using var services = new ServiceCollection() 39using var services = new ServiceCollection() 59using var services = new ServiceCollection() 78using var services = new ServiceCollection() 98using var services = new ServiceCollection() 117using var services = new ServiceCollection() 137using var services = new ServiceCollection() 157using var services = new ServiceCollection() 177using var services = new ServiceCollection() 199using var services = new ServiceCollection() 234Assert.Throws<ArgumentNullException>(() => new ServiceCollection().AddRedaction(x => x.SetFakeRedactor((Action<FakeRedactorOptions>)null!, dc))); 239Assert.Throws<ArgumentNullException>(() => new ServiceCollection().AddFakeRedaction(null!)); 245using var sp = new ServiceCollection().AddFakeRedaction().BuildServiceProvider();
RedactionFakesEventCollectorTests.cs (1)
25using var sp = new ServiceCollection().BuildServiceProvider();
Microsoft.Extensions.Diagnostics.HealthChecks.Common.Tests (9)
ApplicationLifecycleHealthChecksExtensionsTests.cs (3)
19var serviceCollection = new ServiceCollection(); 29var serviceCollection = new ServiceCollection(); 39var serviceCollection = new ServiceCollection();
ManualHealthCheckExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 26var serviceCollection = new ServiceCollection(); 35var serviceCollection = new ServiceCollection();
TelemetryHealthChecksPublisherExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 34var serviceCollection = new ServiceCollection(); 54var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Diagnostics.HealthChecks.Tests (7)
DefaultHealthCheckServiceTest.cs (2)
30var serviceCollection = new ServiceCollection(); 628var services = new ServiceCollection();
DependencyInjection\HealthChecksBuilderTest.cs (2)
205var services = new ServiceCollection(); 225var services = new ServiceCollection();
DependencyInjection\ServiceCollectionExtensionsTest.cs (2)
19var services = new ServiceCollection(); 49var services = new ServiceCollection();
HealthCheckPublisherHostedServiceTest.cs (1)
742var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (11)
Linux\AcceptanceTest.cs (5)
30using var services = new ServiceCollection() 59using var services = new ServiceCollection() 77using var services = new ServiceCollection() 111using var services = new ServiceCollection() 160using var services = new ServiceCollection()
ResourceMonitoringBuilderTests.cs (2)
16using var provider = new ServiceCollection() 37using var provider = new ServiceCollection()
ResourceMonitoringExtensionsTests.cs (4)
23var services = new ServiceCollection(); 34using var provider = new ServiceCollection() 54using var provider = new ServiceCollection() 70using var provider = new ServiceCollection()
Microsoft.Extensions.Diagnostics.Testing.Tests (4)
Logging\FakeLoggerExtensionsTests.cs (4)
18using var serviceProvider = new ServiceCollection() 34using var serviceProvider = new ServiceCollection() 62using var serviceProvider = new ServiceCollection() 82using var serviceProvider = new ServiceCollection()
Microsoft.Extensions.Hosting (2)
HostApplicationBuilder.cs (1)
23private readonly ServiceCollection _serviceCollection = new();
HostBuilder.cs (1)
336var services = new ServiceCollection();
Microsoft.Extensions.Http.Diagnostics.PerformanceTests (8)
HttpClientFactory.cs (8)
16var services = new ServiceCollection(); 40var services = new ServiceCollection(); 63var services = new ServiceCollection(); 90var services = new ServiceCollection(); 113var services = new ServiceCollection(); 136var services = new ServiceCollection(); 162=> new ServiceCollection() 172=> new ServiceCollection()
Microsoft.Extensions.Http.Diagnostics.Tests (38)
Latency\HttpClientLatencyTelemetryExtensionsTest.cs (4)
36using var sp = new ServiceCollection() 60using var sp = new ServiceCollection() 74using var sp = new ServiceCollection() 98using var sp = new ServiceCollection()
Logging\AcceptanceTests.cs (15)
30await using var sp = new ServiceCollection() 62await using var sp = new ServiceCollection() 96await using var sp = new ServiceCollection() 133await using var provider = new ServiceCollection() 210await using var provider = new ServiceCollection() 295await using var sp = new ServiceCollection() 341await using var sp = new ServiceCollection() 406await using var sp = new ServiceCollection() 447using var provider = new ServiceCollection() 481using var provider = new ServiceCollection() 516using var provider = new ServiceCollection() 581await using var provider = new ServiceCollection() 603await using var provider = new ServiceCollection() 631await using var provider = new ServiceCollection() 659await using var provider = new ServiceCollection()
Logging\HttpClientLoggerTest.cs (1)
1011var builder = new ServiceCollection()
Logging\HttpClientLoggingExtensionsTest.cs (12)
82var services = new ServiceCollection(); 105var services = new ServiceCollection(); 128var services = new ServiceCollection(); 159var services = new ServiceCollection(); 229using var provider = new ServiceCollection() 244using var provider = new ServiceCollection() 268var services = new ServiceCollection(); 314using var provider = new ServiceCollection() 336using var provider = new ServiceCollection() 359using var provider = new ServiceCollection() 379using var provider = new ServiceCollection() 397using var sp = new ServiceCollection()
Logging\HttpRequestReaderTest.cs (1)
581var services = new ServiceCollection();
Telemetry\DownstreamDependencyMetadataManagerTests.cs (1)
19_sp = new ServiceCollection()
TelemetryCommonExtensionsTests.cs (4)
40var sp = new ServiceCollection().AddFakeRedaction().AddHttpRouteProcessor().BuildServiceProvider(); 55var sp = new ServiceCollection().AddFakeRedaction().AddHttpHeadersRedactor().BuildServiceProvider(); 63var serviceCollection = new ServiceCollection(); 87var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Http.Polly.Tests (14)
DependencyInjection\PollyHttpClientBuilderExtensionsTest.cs (14)
41var serviceCollection = new ServiceCollection(); 76var serviceCollection = new ServiceCollection(); 114var serviceCollection = new ServiceCollection(); 152var serviceCollection = new ServiceCollection(); 190var serviceCollection = new ServiceCollection(); 252var serviceCollection = new ServiceCollection(); 297var serviceCollection = new ServiceCollection(); 332var serviceCollection = new ServiceCollection(); 402var serviceCollection = new ServiceCollection(); 446var serviceCollection = new ServiceCollection(); 463var serviceCollection = new ServiceCollection(); 480var serviceCollection = new ServiceCollection(); 501var serviceCollection = new ServiceCollection(); 530var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Http.Resilience.PerformanceTests (3)
HttpClientFactory.cs (1)
36var services = new ServiceCollection();
RetryBenchmark.cs (1)
32var services = new ServiceCollection();
StandardResilienceBenchmark.cs (1)
32var services = new ServiceCollection();
Microsoft.Extensions.Http.Resilience.Tests (24)
Hedging\HedgingTests.cs (1)
47_services = new ServiceCollection().AddMetrics().AddLogging();
Hedging\StandardHedgingTests.cs (1)
308var services = new ServiceCollection();
Resilience\HttpClientBuilderExtensionsTests.Resilience.cs (9)
28var services = new ServiceCollection(); 46var services = new ServiceCollection(); 66var services = new ServiceCollection(); 89var services = new ServiceCollection(); 119var clientBuilder = new ServiceCollection() 169var services = new ServiceCollection(); 203var services = new ServiceCollection().AddLogging().AddMetrics().AddFakeRedaction(); 247var services = new ServiceCollection().AddLogging().AddMetrics(); 278var clientBuilder = new ServiceCollection().AddLogging().AddMetrics().AddRedaction()
Resilience\HttpClientBuilderExtensionsTests.Standard.cs (9)
31_builder = new ServiceCollection().AddHttpClient(BuilderName); 115var builder = new ServiceCollection().AddHttpClient("test"); 126var builder = new ServiceCollection().AddHttpClient("test"); 136var builder = new ServiceCollection().AddHttpClient("test"); 146var builder = new ServiceCollection().AddLogging().AddMetrics().AddHttpClient("test"); 156using var serviceProvider = new ServiceCollection() 182var builder = new ServiceCollection().AddLogging().AddMetrics().AddHttpClient("test"); 211var builder = new ServiceCollection().AddLogging().AddMetrics().AddHttpClient("test"); 264var builder = new ServiceCollection().AddLogging().AddMetrics().AddHttpClient("test").AddStandardResilienceHandler();
Routing\RoutingStrategyTest.cs (4)
26Builder = new RoutingStrategyBuilder(RoutingName, new ServiceCollection()); 81Builder = new RoutingStrategyBuilder(RoutingName, new ServiceCollection()); 100Builder = new RoutingStrategyBuilder(RoutingName, new ServiceCollection()); 136Builder = new RoutingStrategyBuilder(RoutingName, new ServiceCollection());
Microsoft.Extensions.Localization.Tests (2)
LocalizationServiceCollectionExtensionsTest.cs (2)
17var collection = new ServiceCollection(); 31var collection = new ServiceCollection();
Microsoft.Extensions.Logging (1)
LoggerFactory.cs (1)
113var serviceCollection = new ServiceCollection();
Microsoft.Extensions.ML.Tests (7)
FileLoaderTests.cs (3)
29var services = new ServiceCollection() 42var services = new ServiceCollection() 61var services = new ServiceCollection()
PredictionEnginePoolTests.cs (1)
29var services = new ServiceCollection()
UriLoaderTests.cs (3)
29var services = new ServiceCollection() 42var services = new ServiceCollection() 61var services = new ServiceCollection()
Microsoft.Extensions.ObjectPool.DependencyInjection.Tests (15)
DependencyInjectionExtensionsTests.cs (15)
34() => new ServiceCollection().ConfigurePools(builder.Build().GetSection("My:Pools"))); 51var services = new ServiceCollection().ConfigurePools(builder.Build().GetSection("My:Pools")); 63var services = new ServiceCollection() 81Assert.Throws<ArgumentNullException>(() => new ServiceCollection().ConfigurePools(null!)); 87var services = new ServiceCollection().AddPooled<TestDependency>(); 98var services = new ServiceCollection() 115var services = new ServiceCollection().AddPooled<TestDependency>(options => options.Capacity = 64); 128var services = new ServiceCollection() 142var services = new ServiceCollection() 158var services = new ServiceCollection() 177var services = new ServiceCollection() 212var services = new ServiceCollection() 223var services = new ServiceCollection() 258var services = new ServiceCollection() 315var services = new ServiceCollection()
Microsoft.Extensions.Options.Contextual.Tests (5)
ContextualOptionsServiceCollectionExtensionsTests.cs (5)
22using var provider = new ServiceCollection().AddContextualOptions().BuildServiceProvider(); 35using var provider = new ServiceCollection().Configure(loadOptions).BuildServiceProvider(); 45using var provider = new ServiceCollection().Configure(configureOptions).BuildServiceProvider(); 57using var provider = new ServiceCollection().ConfigureAll(loadOptions).BuildServiceProvider(); 67using var provider = new ServiceCollection().ConfigureAll(configureOptions).BuildServiceProvider();
Microsoft.Extensions.Resilience.PerformanceTests (1)
ResilienceEnrichmentBenchmark.cs (1)
40var services = new ServiceCollection();
Microsoft.Extensions.Resilience.Tests (2)
Resilience\ResilienceServiceCollectionExtensionsTests.cs (2)
27_services = new ServiceCollection().AddResilienceEnricher(); 46var services = new ServiceCollection().AddResilienceEnricher();
Microsoft.Extensions.ServiceDiscovery.Dns.Tests (5)
DnsServiceEndpointResolverTests.cs (1)
17var services = new ServiceCollection()
DnsServicePublicApiTests.cs (2)
38IServiceCollection services = new ServiceCollection(); 73IServiceCollection services = new ServiceCollection();
DnsSrvServiceEndpointResolverTests.cs (2)
102var services = new ServiceCollection() 173var serviceCollection = new ServiceCollection()
Microsoft.Extensions.ServiceDiscovery.Tests (19)
ConfigurationServiceEndpointResolverTests.cs (7)
27var services = new ServiceCollection() 63var services = new ServiceCollection() 144var services = new ServiceCollection() 244var services = new ServiceCollection() 286var services = new ServiceCollection() 353var services = new ServiceCollection() 398var services = new ServiceCollection()
PassThroughServiceEndpointResolverTests.cs (4)
23var services = new ServiceCollection() 54var services = new ServiceCollection() 87var services = new ServiceCollection() 121var services = new ServiceCollection()
ServiceEndpointResolverTests.cs (8)
25var services = new ServiceCollection() 36var services = new ServiceCollection() 49var services = new ServiceCollection() 59var serviceCollection = new ServiceCollection(); 102var services = new ServiceCollection() 154var services = new ServiceCollection() 190var services = new ServiceCollection() 235var services = new ServiceCollection()
Microsoft.Extensions.ServiceDiscovery.Yarp.Tests (7)
YarpServiceDiscoveryTests.cs (7)
32await using var services = new ServiceCollection() 62await using var services = new ServiceCollection() 92await using var services = new ServiceCollection() 126await using var services = new ServiceCollection() 205await using var services = new ServiceCollection() 235await using var services = new ServiceCollection() 293await using var services = new ServiceCollection()
Microsoft.Extensions.Telemetry.Abstractions.Tests (13)
Enrichment\EnricherExtensionsTests.cs (4)
16Assert.Throws<ArgumentNullException>(() => new ServiceCollection().AddLogEnricher(null!)); 30new ServiceCollection().AddLogEnricher(null!)); 36var services = new ServiceCollection(); 55var services = new ServiceCollection();
Latency\LatencyRegistryExtensionsTests.cs (7)
17() => LatencyRegistryServiceCollectionExtensions.RegisterCheckpointNames(new ServiceCollection(), null!)); 23() => LatencyRegistryServiceCollectionExtensions.RegisterMeasureNames(new ServiceCollection(), null!)); 27() => LatencyRegistryServiceCollectionExtensions.RegisterTagNames(new ServiceCollection(), null!)); 33Assert.Throws<ArgumentException>(() => LatencyRegistryServiceCollectionExtensions.RegisterCheckpointNames(new ServiceCollection(), "")); 34Assert.Throws<ArgumentException>(() => LatencyRegistryServiceCollectionExtensions.RegisterMeasureNames(new ServiceCollection(), "")); 35Assert.Throws<ArgumentException>(() => LatencyRegistryServiceCollectionExtensions.RegisterTagNames(new ServiceCollection(), "")); 41var services = RegisterNames(new ServiceCollection());
Latency\NoopLatencyContextTests.cs (2)
22using var serviceProvider = new ServiceCollection() 34using var serviceProvider = new ServiceCollection()
Microsoft.Extensions.Telemetry.PerformanceTests (1)
ExtendedLoggerBench.cs (1)
57var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Telemetry.Tests (22)
Enrichment\ApplicationEnricherExtensionsTests.cs (1)
30new ServiceCollection().AddServiceLogEnricher((IConfigurationSection)null!));
Enrichment\ProcessEnricherExtensionsTests.cs (2)
30new ServiceCollection().AddProcessLogEnricher((IConfigurationSection)null!)); 33new ServiceCollection().AddProcessLogEnricher((Action<ProcessLogEnricherOptions>)null!));
Http\HttpParserTests.cs (1)
644var sp = new ServiceCollection().AddHttpRouteProcessor().AddFakeRedaction().BuildServiceProvider();
Http\TelemetryCommonExtensionsTests.cs (1)
38var sp = new ServiceCollection().AddFakeRedaction().AddHttpRouteProcessor().BuildServiceProvider();
Latency\Internal\LatencyContextTests.cs (8)
77using var scope = new ServiceCollection() 103using var scope = new ServiceCollection() 129using var scope = new ServiceCollection() 156using var scope = new ServiceCollection() 187using var scope = new ServiceCollection() 214using var scope = new ServiceCollection() 239using var scope = new ServiceCollection() 264using var scope = new ServiceCollection()
Latency\LatencyConsoleExtensionsTests.cs (4)
19var s = new ServiceCollection(); 28using var serviceProvider = new ServiceCollection() 41using var serviceProvider = new ServiceCollection() 59using var provider = new ServiceCollection()
Latency\LatencyContextExtensionTests.cs (4)
27using var serviceProvider = new ServiceCollection() 43using var serviceProvider = new ServiceCollection() 70using var serviceProvider = new ServiceCollection() 95using var provider = new ServiceCollection()
Logging\Utils.cs (1)
14var serviceCollection = new ServiceCollection();
Microsoft.Extensions.WebEncoders.Tests (3)
EncoderServiceCollectionExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 36var serviceCollection = new ServiceCollection(); 65var serviceCollection = new ServiceCollection();
Microsoft.Gen.Logging.Generated.Tests (1)
Utils.cs (1)
71var serviceCollection = new ServiceCollection();
Microsoft.ML.AutoML (1)
AutoMLExperiment\AutoMLExperiment.cs (1)
55_serviceCollection = new ServiceCollection();
PhotinoTestApp (1)
Program.cs (1)
16var serviceCollection = new ServiceCollection();
Redis (1)
Program.cs (1)
19using (var services = new ServiceCollection()
Shared.Tests (3)
Debugger\DebuggerTest.cs (3)
23using var provider = new ServiceCollection() 36using var provider = new ServiceCollection() 49using var provider = new ServiceCollection()
Wasm.Performance.ConsoleHost (1)
Scenarios\ComponentRenderingScenarioBase.cs (1)
26var serviceCollection = new ServiceCollection();
663 references to ServiceCollection
Aspire.EndToEnd.Tests (1)
tests\Shared\WorkloadTesting\AspireProject.cs (1)
455var services = new ServiceCollection();
Aspire.Hosting.Testing.Tests (1)
DistributedApplicationHttpClientExtensionsForTests.cs (1)
21var services = new ServiceCollection();
Aspire.Hosting.Tests (1)
tests\Aspire.Hosting.Testing.Tests\DistributedApplicationHttpClientExtensionsForTests.cs (1)
21var services = new ServiceCollection();
Aspire.Workload.Tests (1)
tests\Shared\WorkloadTesting\AspireProject.cs (1)
455var services = new ServiceCollection();
InteropClient (1)
InteropClient.cs (1)
92var services = new ServiceCollection();
KeyManagementSample (1)
Program.cs (1)
16var serviceCollection = new ServiceCollection();
Microsoft.Arcade.Common (1)
MSBuildTaskBase.cs (1)
32ServiceCollection collection = new ServiceCollection();
Microsoft.AspNetCore.Antiforgery.Test (8)
AntiforgeryApplicationBuilderExtensionsTest.cs (1)
52var services = new ServiceCollection();
AntiforgeryOptionsSetupTest.cs (2)
21var serviceCollection = new ServiceCollection(); 41var serviceCollection = new ServiceCollection();
DefaultAntiforgeryTest.cs (5)
353var services = new ServiceCollection(); 1284var services = new ServiceCollection(); 1322var services = new ServiceCollection(); 1356var services = new ServiceCollection(); 1403var builder = new ServiceCollection();
Microsoft.AspNetCore.AsyncState.Tests (1)
AsyncStateHttpContextExtensionsTests.cs (1)
24var services = new ServiceCollection();
Microsoft.AspNetCore.Authentication.Test (10)
AuthenticationMiddlewareTests.cs (1)
205var serviceCollection = new ServiceCollection();
BearerTokenTests.cs (1)
16var services = new ServiceCollection();
CookieTests.cs (1)
287var services = new ServiceCollection();
JwtBearerTests_Handler.cs (4)
959var services = new ServiceCollection(); 1020var services = new ServiceCollection(); 1049var services = new ServiceCollection(); 1069var services = new ServiceCollection();
SecureDataFormatTests.cs (1)
14var serviceCollection = new ServiceCollection();
WsFederation\WsFederationTest.cs (1)
29var services = new ServiceCollection();
WsFederation\WsFederationTest_Handler.cs (1)
27var services = new ServiceCollection();
Microsoft.AspNetCore.Authorization.Test (6)
AuthorizationAppBuilderExtensionsTests.cs (1)
66var services = new ServiceCollection();
AuthorizationBuilderTests.cs (1)
111var services = new ServiceCollection();
AuthorizationMiddlewareResultHandlerTests.cs (1)
136var services = new ServiceCollection();
AuthorizationMiddlewareTests.cs (1)
1033var serviceCollection = new ServiceCollection();
DefaultAuthorizationServiceTests.cs (1)
16var services = new ServiceCollection();
PassThroughAuthorizationHandlerTests.cs (1)
14var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Authorization.Tests (5)
AuthorizeRouteViewTest.cs (1)
30var serviceCollection = new ServiceCollection();
AuthorizeViewTest.cs (1)
566var serviceCollection = new ServiceCollection();
CascadingAuthenticationStateTest.cs (3)
36var services = new ServiceCollection(); 68var services = new ServiceCollection(); 121var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Endpoints.Tests (10)
Builder\RazorComponentsEndpointConventionBuilderExtensionsTest.cs (1)
273var collection = new ServiceCollection();
EndpointHtmlRendererTest.cs (3)
662var collection = CreateDefaultServiceCollection(); 1666private static ServiceCollection CreateDefaultServiceCollection() 1668var services = new ServiceCollection();
HotReloadServiceTests.cs (1)
217var services = new ServiceCollection();
ImportMapTest.cs (1)
22var services = new ServiceCollection();
RazorComponentEndpointDataSourceTest.cs (1)
220var services = new ServiceCollection();
RazorComponentsServiceCollectionExtensionsTest.cs (3)
19var services = new ServiceCollection(); 46var services = new ServiceCollection(); 75var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Server.Tests (6)
Circuits\CircuitHostTest.cs (1)
644var serviceCollection = new ServiceCollection();
Circuits\RemoteRendererTest.cs (1)
639var serviceCollection = new ServiceCollection();
ComponentEndpointRouteBuilderExtensionsTest.cs (1)
130var services = new ServiceCollection();
DependencyInjection\ComponentServiceCollectionExtensionsTest.cs (3)
17var services = new ServiceCollection(); 32var services = new ServiceCollection(); 54var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Tests (14)
CascadingParameterTest.cs (11)
445var services = new ServiceCollection(); 492var services = new ServiceCollection(); 520var services = new ServiceCollection(); 559var services = new ServiceCollection(); 574var services = new ServiceCollection(); 641var services = new ServiceCollection(); 696var services = new ServiceCollection(); 789var services = new ServiceCollection(); 804var services = new ServiceCollection(); 819var services = new ServiceCollection(); 840var services = new ServiceCollection();
OwningComponentBaseTest.cs (1)
14var services = new ServiceCollection();
RouteViewTest.cs (1)
20var serviceCollection = new ServiceCollection();
Routing\RouterTest.cs (1)
21var services = new ServiceCollection();
Microsoft.AspNetCore.Components.Web.Tests (6)
Forms\EditFormTest.cs (1)
19var services = new ServiceCollection();
Forms\InputNumberTest.cs (1)
18var services = new ServiceCollection();
Forms\Mapping\FormMappingScopeTest.cs (1)
18var serviceCollection = new ServiceCollection();
Forms\Mapping\SupplyParameterFromFormTest.cs (1)
63var services = new ServiceCollection();
HtmlRendering\HtmlRendererTest.cs (2)
1375var services = new ServiceCollection(); 1415var services = new ServiceCollection();
Microsoft.AspNetCore.Components.WebViewE2E.Test (1)
BasicBlazorHybridTest.cs (1)
40var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.DataProtection.Extensions (1)
DataProtectionProvider.cs (1)
127var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.DataProtection.Tests (12)
ActivatorTests.cs (2)
16var serviceCollection = new ServiceCollection(); 72var serviceCollection = new ServiceCollection();
KeyManagement\KeyEscrowServiceProviderExtensionsTests.cs (2)
42var serviceCollection = new ServiceCollection(); 74var serviceCollection = new ServiceCollection();
TypeForwardingActivatorTests.cs (2)
14var serviceCollection = new ServiceCollection(); 31var serviceCollection = new ServiceCollection();
XmlEncryption\CertificateXmlEncryptionTests.cs (1)
38var serviceCollection = new ServiceCollection();
XmlEncryption\XmlEncryptionExtensionsTests.cs (5)
40var serviceCollection = new ServiceCollection(); 67var serviceCollection = new ServiceCollection(); 101var serviceCollection = new ServiceCollection(); 133var serviceCollection = new ServiceCollection(); 184var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (2)
Logging\HttpLoggingServiceExtensionsTests.cs (2)
34var services = new ServiceCollection(); 58var services = new ServiceCollection();
Microsoft.AspNetCore.Grpc.JsonTranscoding.Tests (5)
GrpcJsonTranscodingServiceExtensionsTests.cs (2)
15var services = new ServiceCollection(); 37var services = new ServiceCollection();
Infrastructure\TestHelpers.cs (1)
22var serviceCollection = new ServiceCollection();
JsonTranscodingServerCallContextTests.cs (1)
61var serviceCollection = new ServiceCollection();
JsonTranscodingServiceMethodProviderTests.cs (1)
264var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Grpc.Swagger.Tests (3)
GrpcSwaggerServiceExtensionsTests.cs (2)
22var services = new ServiceCollection(); 57var services = new ServiceCollection();
Infrastructure\OpenApiTestHelpers.cs (1)
18var services = new ServiceCollection();
Microsoft.AspNetCore.HeaderPropagation.Tests (1)
HeaderPropagationIntegrationTest.cs (1)
80var services = new ServiceCollection();
Microsoft.AspNetCore.Hosting (2)
WebHostBuilder.cs (2)
265var services = new ServiceCollection(); 314private void ScanAssemblyAndRegisterStartup(ServiceCollection services, string startupAssemblyName)
Microsoft.AspNetCore.Hosting.Tests (27)
HostingApplicationTests.cs (1)
183var services = new ServiceCollection();
HostingMetricsTests.cs (1)
189var services = new ServiceCollection();
StartupManagerTests.cs (25)
19var serviceCollection = new ServiceCollection(); 41var serviceCollection = new ServiceCollection(); 63var serviceCollection = new ServiceCollection(); 87var serviceCollection = new ServiceCollection(); 109var serviceCollection = new ServiceCollection(); 131var serviceCollection = new ServiceCollection(); 292var serviceCollection = new ServiceCollection(); 310var serviceCollection = new ServiceCollection(); 362var serviceCollection = new ServiceCollection(); 409var serviceCollection = new ServiceCollection(); 423var serviceCollection = new ServiceCollection(); 438var serviceCollection = new ServiceCollection(); 452var serviceCollection = new ServiceCollection(); 469var serviceCollection = new ServiceCollection(); 487var serviceCollection = new ServiceCollection(); 505var serviceCollection = new ServiceCollection(); 520var serviceCollection = new ServiceCollection(); 534var serviceCollection = new ServiceCollection(); 549var serviceCollection = new ServiceCollection(); 565var serviceCollection = new ServiceCollection(); 581var serviceCollection = new ServiceCollection(); 597var serviceCollection = new ServiceCollection(); 608var serviceCollection = new ServiceCollection(); 617var serviceCollection = new ServiceCollection(); 627var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Http.Connections.Tests (69)
HttpConnectionDispatcherTests.cs (69)
62var services = new ServiceCollection(); 86var services = new ServiceCollection(); 112var services = new ServiceCollection(); 149var services = new ServiceCollection(); 177var services = new ServiceCollection(); 223var services = new ServiceCollection(); 264var services = new ServiceCollection(); 303var services = new ServiceCollection(); 345var services = new ServiceCollection(); 383var services = new ServiceCollection(); 422var services = new ServiceCollection(); 462var services = new ServiceCollection(); 525var services = new ServiceCollection(); 593var services = new ServiceCollection(); 656var services = new ServiceCollection(); 719var services = new ServiceCollection(); 758var services = new ServiceCollection(); 855var services = new ServiceCollection(); 902var services = new ServiceCollection(); 931var services = new ServiceCollection(); 1006var services = new ServiceCollection(); 1039var services = new ServiceCollection(); 1067var services = new ServiceCollection(); 1103var services = new ServiceCollection(); 1139var services = new ServiceCollection(); 1190var services = new ServiceCollection(); 1285var services = new ServiceCollection(); 1325var services = new ServiceCollection(); 1370var services = new ServiceCollection(); 1410var services = new ServiceCollection(); 1439var services = new ServiceCollection(); 1485var services = new ServiceCollection(); 1550var services = new ServiceCollection(); 1614var services = new ServiceCollection(); 1645var services = new ServiceCollection(); 1679var services = new ServiceCollection(); 1714var services = new ServiceCollection(); 1756var services = new ServiceCollection(); 1802var services = new ServiceCollection(); 1834var services = new ServiceCollection(); 1886var services = new ServiceCollection(); 1940var services = new ServiceCollection(); 1987var services = new ServiceCollection(); 2019var serviceCollection = new ServiceCollection(); 2060var services = new ServiceCollection(); 2113var services = new ServiceCollection(); 2166var services = new ServiceCollection(); 2266var services = new ServiceCollection(); 2292var services = new ServiceCollection(); 2321var services = new ServiceCollection(); 2350var services = new ServiceCollection(); 2383var services = new ServiceCollection(); 2457var services = new ServiceCollection(); 2554var services = new ServiceCollection(); 2616var services = new ServiceCollection(); 2673var services = new ServiceCollection(); 2732var services = new ServiceCollection(); 2772var services = new ServiceCollection(); 2821var services = new ServiceCollection(); 2848var services = new ServiceCollection(); 2878var services = new ServiceCollection(); 2925var services = new ServiceCollection(); 2961var services = new ServiceCollection(); 3012var services = new ServiceCollection(); 3067var services = new ServiceCollection(); 3112var services = new ServiceCollection(); 3152var services = new ServiceCollection(); 3574var services = new ServiceCollection(); 3693var services = new ServiceCollection();
Microsoft.AspNetCore.Http.Extensions.Tests (16)
ProblemDetailsDefaultWriterTest.cs (1)
694var services = new ServiceCollection();
ProblemDetailsServiceCollectionExtensionsTest.cs (10)
22var collection = new ServiceCollection(); 37var collection = new ServiceCollection(); 53var collection = new ServiceCollection(); 73var collection = new ServiceCollection(); 89var collection = new ServiceCollection(); 110var collection = new ServiceCollection(); 142var collection = new ServiceCollection(); 175var collection = new ServiceCollection(); 195var collection = new ServiceCollection(); 217var collection = new ServiceCollection();
RequestDelegateFactoryTests.cs (2)
1172var serviceCollection = new ServiceCollection(); 1736var serviceCollection = new ServiceCollection();
RequestDelegateGenerator\RequestDelegateCreationTestBase.cs (1)
210var serviceCollection = new ServiceCollection();
RequestDelegateGenerator\RequestDelegateCreationTests.cs (2)
270var serviceCollection = new ServiceCollection(); 299var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Http.Microbenchmarks (1)
src\Http\Http.Extensions\test\RequestDelegateGenerator\RequestDelegateCreationTestBase.cs (1)
210var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Http.Results.Tests (41)
AcceptedAtRouteOfTResultTests.cs (1)
221var services = new ServiceCollection();
AcceptedAtRouteResultTests.cs (1)
131var services = new ServiceCollection();
AcceptedOfTResultTests.cs (1)
145var services = new ServiceCollection();
AcceptedResultTests.cs (1)
88var services = new ServiceCollection();
BadRequestOfTResultTests.cs (1)
181var services = new ServiceCollection();
BadRequestResultTests.cs (1)
94var services = new ServiceCollection();
ChallengeResultTests.cs (1)
66var services = new ServiceCollection();
ConflictOfTResultTests.cs (1)
159var services = new ServiceCollection();
ConflictResultTests.cs (1)
95var services = new ServiceCollection();
ContentResultTests.cs (1)
172var services = new ServiceCollection();
CreatedAtRouteOfTResultTests.cs (1)
190var services = new ServiceCollection();
CreatedAtRouteResultTests.cs (1)
136var services = new ServiceCollection();
CreatedOfTResultTests.cs (1)
187var services = new ServiceCollection();
CreatedResultTests.cs (1)
124var services = new ServiceCollection();
ForbidResultTests.cs (1)
133var services = new ServiceCollection();
HttpResultsHelperTests.cs (1)
244var services = new ServiceCollection();
InternalServerErrorOfTResultTests.cs (1)
181var services = new ServiceCollection();
InternalServerErrorResultTests.cs (1)
94var services = new ServiceCollection();
JsonResultTests.cs (1)
315var services = new ServiceCollection();
LocalRedirectResultTests.cs (1)
122var serviceCollection = new ServiceCollection();
NoContentResultTests.cs (1)
91var services = new ServiceCollection();
NotFoundOfTResultTests.cs (1)
150var services = new ServiceCollection();
NotFoundResultTests.cs (1)
99var services = new ServiceCollection();
OkOfTResultTests.cs (1)
158var services = new ServiceCollection();
OkResultTests.cs (1)
93var services = new ServiceCollection();
ProblemResultTests.cs (1)
252var services = new ServiceCollection();
RedirectToRouteResultTests.cs (1)
110var services = new ServiceCollection();
ResultsOfTTests.cs (1)
55var services = new ServiceCollection();
SignInResultTests.cs (1)
99var services = new ServiceCollection();
SignOutResultTests.cs (1)
98var services = new ServiceCollection();
src\Shared\ResultsTests\FileContentResultTestBase.cs (1)
355var services = new ServiceCollection();
src\Shared\ResultsTests\FileStreamResultTestBase.cs (1)
443var services = new ServiceCollection();
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
460var services = new ServiceCollection();
src\Shared\ResultsTests\RedirectResultTestBase.cs (1)
63var serviceCollection = new ServiceCollection();
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
487var services = new ServiceCollection();
StatusCodeResultTests.cs (1)
48var services = new ServiceCollection();
UnauthorizedResultTests.cs (1)
58var services = new ServiceCollection();
UnprocessableEntityOfTResultTests.cs (1)
158var services = new ServiceCollection();
UnprocessableEntityResultTests.cs (1)
94var services = new ServiceCollection();
Utf8ContentResultTests.cs (1)
90var services = new ServiceCollection();
ValidationProblemResultTests.cs (1)
178var services = new ServiceCollection();
Microsoft.AspNetCore.Http.Tests (4)
ApplicationBuilderTests.cs (2)
82var services = new ServiceCollection(); 108var services = new ServiceCollection();
HttpServiceCollectionExtensionsTests.cs (1)
14var services = new ServiceCollection();
ResponseCookiesTest.cs (1)
29var services = new ServiceCollection();
Microsoft.AspNetCore.HttpLogging.Tests (3)
HttpLoggingServicesExtensionsTests.cs (3)
28var services = new ServiceCollection(); 40var services = new ServiceCollection(); 52var services = new ServiceCollection();
Microsoft.AspNetCore.Identity.EntityFrameworkCore.Test (17)
CustomSchemaTest.cs (1)
19var services = new ServiceCollection();
DefaultPocoTest.cs (1)
20var services = new ServiceCollection();
EmptySchemaTest.cs (1)
19var services = new ServiceCollection();
MaxKeyLengthSchemaTest.cs (1)
20var services = new ServiceCollection();
SqlStoreTestBase.cs (1)
95var services = new ServiceCollection();
UserOnlyCustomContextTest.cs (1)
64var services = new ServiceCollection();
UserOnlyTest.cs (1)
25var services = new ServiceCollection();
UserStoreGuidKeyTest.cs (2)
57var services = new ServiceCollection(); 74var services = new ServiceCollection();
UserStoreIntKeyTest.cs (2)
35var services = new ServiceCollection(); 52var services = new ServiceCollection();
UserStoreStringKeyTest.cs (2)
36var services = new ServiceCollection(); 53var services = new ServiceCollection();
UserStoreWithGenericsTest.cs (2)
81var services = new ServiceCollection(); 90var services = new ServiceCollection();
VersionOneSchemaTest.cs (1)
19var services = new ServiceCollection();
VersionTwoSchemaTest.cs (1)
19var services = new ServiceCollection();
Microsoft.AspNetCore.Identity.Test (10)
IdentityBuilderTest.cs (2)
16var services = new ServiceCollection(); 44var services = new ServiceCollection();
IdentityOptionsTest.cs (2)
60var services = new ServiceCollection(); 74var services = new ServiceCollection();
SecurityStampValidatorTest.cs (6)
119var services = new ServiceCollection(); 173var services = new ServiceCollection(); 214var services = new ServiceCollection(); 252var services = new ServiceCollection(); 290var services = new ServiceCollection(); 339var services = new ServiceCollection();
Microsoft.AspNetCore.InternalTesting (2)
AssemblyTestLog.cs (2)
163var serviceCollection = new ServiceCollection(); 195var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.InternalTesting.Tests (1)
LoggedTestXunitTests.cs (1)
109var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (1)
EndpointMetadataApiDescriptionProviderTest.cs (1)
1533var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Core.Test (75)
AcceptedAtActionResultTests.cs (1)
270var services = new ServiceCollection();
AcceptedAtRouteResultTests.cs (1)
178var services = new ServiceCollection();
AcceptedResultTests.cs (1)
135var services = new ServiceCollection();
ApplicationModels\EndpointMetadataProviderTest.cs (1)
267var services = new ServiceCollection();
Authorization\AuthorizeFilterTest.cs (1)
598var serviceCollection = new ServiceCollection();
Builder\MvcApplicationBuilderExtensionsTest.cs (2)
38var services = new ServiceCollection(); 63var services = new ServiceCollection();
Builder\MvcAreaRouteBuilderExtensionsTest.cs (1)
271var services = new ServiceCollection();
ChallengeResultTest.cs (1)
70var services = new ServiceCollection();
ContentResultTest.cs (1)
266var services = new ServiceCollection();
ControllerBaseTest.cs (1)
3197var services = new ServiceCollection();
Controllers\ControllerBinderDelegateProviderTest.cs (1)
1251var services = new ServiceCollection();
CreatedAtActionResultTests.cs (1)
90var services = new ServiceCollection();
CreatedAtRouteResultTests.cs (1)
104var services = new ServiceCollection();
CreatedResultTests.cs (1)
137var services = new ServiceCollection();
DependencyInjection\MvcBuilderExtensionsTest.cs (2)
83var collection = new ServiceCollection(); 115var services = new ServiceCollection();
DependencyInjection\MvcCoreServiceCollectionExtensionsTest.cs (9)
34var services = new ServiceCollection(); 62var services = new ServiceCollection(); 85var services = new ServiceCollection(); 113var services = new ServiceCollection(); 131var services = new ServiceCollection(); 150var services = new ServiceCollection(); 171var services = new ServiceCollection(); 194var services = new ServiceCollection(); 218var services = new ServiceCollection();
FileResultHelperTest.cs (1)
462var services = new ServiceCollection();
Filters\MiddlewareFilterAttributeTest.cs (1)
16var services = new ServiceCollection();
Filters\MiddlewareFilterBuilderTest.cs (6)
21var services = new ServiceCollection(); 46var services = new ServiceCollection(); 79var services = new ServiceCollection(); 108var services = new ServiceCollection(); 160var services = new ServiceCollection(); 228var services = new ServiceCollection();
Filters\MiddlewareFilterConfigurationProviderTest.cs (2)
48var services = new ServiceCollection(); 93private IApplicationBuilder GetApplicationBuilder(ServiceCollection services = null)
Filters\MiddlewareFilterTest.cs (2)
321var applicationServices = new ServiceCollection(); 334var services = new ServiceCollection();
HttpActionResultTests.cs (1)
53var services = new ServiceCollection();
HttpNotFoundObjectResultTest.cs (1)
70var services = new ServiceCollection();
HttpOkObjectResultTest.cs (1)
72var services = new ServiceCollection();
HttpOkResultTest.cs (1)
44var services = new ServiceCollection();
HttpStatusCodeResultTests.cs (1)
50var services = new ServiceCollection();
Infrastructure\ControllerActionInvokerTest.cs (1)
1707var services = new ServiceCollection();
Infrastructure\DefaultApiProblemDetailsWriterTest.cs (1)
217var services = new ServiceCollection();
Infrastructure\JsonResultExecutorTestBase.cs (1)
483var services = new ServiceCollection();
Infrastructure\ObjectResultExecutorTest.cs (1)
460var services = new ServiceCollection();
LocalRedirectResultTest.cs (1)
138var serviceCollection = new ServiceCollection();
ModelBinding\Binders\HeaderModelBinderTests.cs (1)
341var services = new ServiceCollection();
ModelBinding\Binders\ServicesModelBinderTest.cs (1)
39var services = new ServiceCollection();
ModelBinding\DefaultModelBindingContextTest.cs (1)
157var services = new ServiceCollection();
ModelBinding\ModelBinderFactoryTest.cs (1)
641var services = new ServiceCollection();
ModelBinding\ModelBindingHelperTest.cs (1)
1495var services = new ServiceCollection();
ModelBinding\ParameterBinderTest.cs (1)
706var services = new ServiceCollection();
ModelBinding\TestModelBinderProviderContext.cs (1)
99var services = new ServiceCollection();
ObjectResultTests.cs (1)
158var services = new ServiceCollection();
PhysicalFileResultTest.cs (1)
58var services = new ServiceCollection();
RedirectResultTest.cs (1)
27var serviceCollection = new ServiceCollection();
RedirectToActionResultTest.cs (1)
149var services = new ServiceCollection();
RedirectToPageResultTest.cs (1)
294var services = new ServiceCollection();
RedirectToRouteResultTest.cs (1)
177var services = new ServiceCollection();
RequireHttpsAttributeTests.cs (1)
239var services = new ServiceCollection();
Routing\ActionEndpointDataSourceBaseTest.cs (1)
137var services = new ServiceCollection();
Routing\ActionEndpointFactoryTest.cs (1)
19var serviceCollection = new ServiceCollection();
Routing\ControllerLinkGeneratorExtensionsTest.cs (1)
214var services = new ServiceCollection();
Routing\DynamicControllerEndpointMatcherPolicyTest.cs (1)
66var services = new ServiceCollection();
Routing\KnownRouteValueConstraintTests.cs (1)
29var services = new ServiceCollection();
Routing\PageLinkGeneratorExtensionsTest.cs (1)
184var services = new ServiceCollection();
Routing\UrlHelperBaseTest.cs (1)
104var services = new ServiceCollection();
Routing\UrlHelperTestBase.cs (1)
1160var services = new ServiceCollection();
src\Shared\ResultsTests\FileContentResultTestBase.cs (1)
355var services = new ServiceCollection();
src\Shared\ResultsTests\FileStreamResultTestBase.cs (1)
443var services = new ServiceCollection();
src\Shared\ResultsTests\PhysicalFileResultTestBase.cs (1)
460var services = new ServiceCollection();
src\Shared\ResultsTests\RedirectResultTestBase.cs (1)
63var serviceCollection = new ServiceCollection();
src\Shared\ResultsTests\VirtualFileResultTestBase.cs (1)
487var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Core.TestCommon (1)
TestModelBinderFactory.cs (1)
82var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Cors.Test (1)
CorsAuthorizationFilterTest.cs (1)
144var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (1)
MvcDataAnnotationsMvcOptionsSetup.cs (1)
17var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.IntegrationTests (4)
AuthorizeFilterIntegrationTest.cs (1)
178var serviceCollection = new ServiceCollection();
HasValidatorsValidationMetadataProviderIntegrationTest.cs (2)
19var serviceCollection = new ServiceCollection(); 34var serviceCollection = new ServiceCollection();
ModelBindingTestHelper.cs (1)
167var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Localization.Test (2)
MvcLocalizationServiceCollectionExtensionsTest.cs (2)
18var collection = new ServiceCollection(); 35var collection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.NewtonsoftJson.Test (4)
DependencyInjection\NewtonsoftJsonMvcBuilderExtensionsTest.cs (1)
16var services = new ServiceCollection();
DependencyInjection\NewtonsoftJsonMvcCoreBuilderExtensionsTest.cs (1)
20var services = new ServiceCollection();
JsonResultTest.cs (1)
51var services = new ServiceCollection();
src\Mvc\Mvc.Core\test\Infrastructure\JsonResultExecutorTestBase.cs (1)
483var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Razor.Test (11)
DefaultTagHelperFactoryTest.cs (4)
26var services = new ServiceCollection(); 53var services = new ServiceCollection(); 71var services = new ServiceCollection(); 99var services = new ServiceCollection();
DependencyInjection\MvcRazorMvcBuilderExtensionsTest.cs (2)
17var services = new ServiceCollection(); 36var services = new ServiceCollection();
DependencyInjection\MvcRazorMvcCoreBuilderExtensionsTest.cs (4)
19var services = new ServiceCollection(); 35var services = new ServiceCollection(); 56var services = new ServiceCollection(); 76var services = new ServiceCollection();
RazorPageCreateModelExpressionTest.cs (1)
315var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Mvc.RazorPages.Test (8)
Builder\PageActionEndpointConventionBuilderResourceCollectionExtensionsTest.cs (1)
215var collection = new ServiceCollection();
Filters\PageSaveTempDataPropertyFilterFactoryTest.cs (1)
33var serviceCollection = new ServiceCollection();
Infrastructure\DefaultPageModelActivatorProviderTest.cs (2)
39var serviceCollection = new ServiceCollection(); 69var serviceCollection = new ServiceCollection();
Infrastructure\DynamicPageEndpointMatcherPolicyTest.cs (1)
57var services = new ServiceCollection();
Infrastructure\PageActionInvokerTest.cs (1)
1500var services = new ServiceCollection();
Infrastructure\PageBinderFactoryTest.cs (1)
785var services = new ServiceCollection();
src\Mvc\Mvc.Core\test\Routing\ActionEndpointDataSourceBaseTest.cs (1)
137var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.Test (19)
MvcOptionsSetupTest.cs (1)
286var serviceCollection = new ServiceCollection();
MvcServiceCollectionExtensionsTest.cs (18)
48var services = new ServiceCollection(); 86var services = new ServiceCollection(); 101var services = new ServiceCollection(); 117var services = new ServiceCollection(); 132var services = new ServiceCollection(); 165var services = new ServiceCollection(); 182var services = new ServiceCollection(); 201var services = new ServiceCollection(); 218var services = new ServiceCollection(); 235var services = new ServiceCollection(); 299var services = new ServiceCollection(); 326var services = new ServiceCollection(); 352var services = new ServiceCollection(); 380var services = new ServiceCollection(); 396var services = new ServiceCollection(); 430var services = new ServiceCollection(); 444var services = new ServiceCollection(); 459var services = new ServiceCollection();
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (27)
Builder\ControllerActionEndpointConventionBuilderResourceCollectionExtensionsTest.cs (1)
288var collection = new ServiceCollection();
DependencyInjection\MvcViewFeaturesMvcBuilderExtensionsTest.cs (2)
127var services = new ServiceCollection(); 160var services = new ServiceCollection();
DependencyInjection\MvcViewFeaturesMvcCoreBuilderExtensionsTest.cs (11)
16var services = new ServiceCollection(); 31var services = new ServiceCollection(); 46var services = new ServiceCollection(); 62var services = new ServiceCollection(); 77var services = new ServiceCollection(); 93var services = new ServiceCollection(); 109var services = new ServiceCollection(); 125var services = new ServiceCollection(); 141var services = new ServiceCollection(); 157var services = new ServiceCollection(); 173var services = new ServiceCollection();
Filters\ControllerSaveTempDataPropertyFilterFactoryTest.cs (1)
29var serviceCollection = new ServiceCollection();
PageRemoteAttributeTest.cs (3)
160var serviceCollection = GetServiceCollection(); 183private static ServiceCollection GetServiceCollection() 185var serviceCollection = new ServiceCollection();
PartialViewResultTest.cs (1)
244var services = new ServiceCollection();
RemoteAttributeBaseTest.cs (1)
468var serviceCollection = new ServiceCollection();
RemoteAttributeTest.cs (4)
363var serviceCollection = GetServiceCollection(); 388var serviceCollection = GetServiceCollection(); 484private static ServiceCollection GetServiceCollection() 486var serviceCollection = new ServiceCollection();
ViewComponentResultTest.cs (1)
661var services = new ServiceCollection();
ViewExecutorTest.cs (1)
162var serviceCollection = new ServiceCollection();
ViewResultTest.cs (1)
256var services = new ServiceCollection();
Microsoft.AspNetCore.OpenApi.Tests (13)
Extensions\OpenApiServiceCollectionExtensionsTests.cs (10)
16var services = new ServiceCollection(); 30var services = new ServiceCollection(); 50var services = new ServiceCollection(); 64var services = new ServiceCollection(); 84var services = new ServiceCollection(); 97var services = new ServiceCollection(); 117var services = new ServiceCollection(); 130var services = new ServiceCollection(); 150var services = new ServiceCollection(); 174var services = new ServiceCollection();
Services\OpenApiSchemaService\OpenApiSchemaService.ParameterSchemas.cs (1)
539var serviceCollection = new ServiceCollection();
Services\OpenApiSchemaService\OpenApiSchemaService.RequestBodySchemas.cs (1)
491var serviceCollection = new ServiceCollection();
Transformers\Implementations\OpenApiSchemaReferenceTransformerTests.cs (1)
426var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.RateLimiting.Tests (5)
RateLimitingApplicationBuilderExtensionsTests.cs (3)
29var services = new ServiceCollection(); 47var services = new ServiceCollection(); 68var services = new ServiceCollection();
RateLimitingMetricsTests.cs (2)
175var services = new ServiceCollection(); 250var services = new ServiceCollection();
Microsoft.AspNetCore.RequestDecompression.Tests (1)
RequestDecompressionServiceExtensionsTests.cs (1)
28var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.Routing.Microbenchmarks (1)
EndpointRoutingBenchmarkBase.cs (1)
29var services = new ServiceCollection();
Microsoft.AspNetCore.Routing.Tests (43)
Builder\EndpointRoutingApplicationBuilderExtensionsTest.cs (1)
351var services = new ServiceCollection();
Builder\RouteHandlerEndpointRouteBuilderExtensionsTest.cs (2)
972var serviceCollection = new ServiceCollection(); 990var appServiceCollection = new ServiceCollection();
Builder\RoutingBuilderExtensionsTest.cs (1)
124var services = new ServiceCollection();
DefaultParameterPolicyFactoryTest.cs (12)
38var services = new ServiceCollection(); 198var services = new ServiceCollection(); 217var services = new ServiceCollection(); 238var services = new ServiceCollection(); 261var services = new ServiceCollection(); 282var services = new ServiceCollection(); 303var services = new ServiceCollection(); 325var services = new ServiceCollection(); 346var services = new ServiceCollection(); 367var services = new ServiceCollection(); 387var services = new ServiceCollection(); 401ServiceCollection services = null)
EndpointRoutingMiddlewareTest.cs (1)
403var services = new ServiceCollection();
Internal\DfaGraphWriterTest.cs (1)
14ServiceCollection services = new ServiceCollection();
LinkGeneratorTestBase.cs (3)
21protected ServiceCollection GetBasicServices() 23var services = new ServiceCollection(); 55var services = GetBasicServices();
LinkParserTestBase.cs (3)
13protected ServiceCollection GetBasicServices() 15var services = new ServiceCollection(); 47var services = GetBasicServices();
Matching\DfaMatcherBuilderTest.cs (1)
3542var serviceCollection = new ServiceCollection();
Matching\MatcherConformanceTest.cs (1)
26var services = new ServiceCollection();
Patterns\DefaultRoutePatternTransformerTest.cs (1)
13var services = new ServiceCollection();
RequestDelegateRouteBuilderExtensionsTest.cs (1)
125var services = new ServiceCollection();
RouteBuilderTest.cs (1)
16var services = new ServiceCollection();
RouteCollectionTest.cs (2)
600var services = new ServiceCollection(); 620var services = new ServiceCollection();
RouteHandlerOptionsTests.cs (3)
20var services = new ServiceCollection(); 36var services = new ServiceCollection(); 60var services = new ServiceCollection();
RouteOptionsTests.cs (2)
16var services = new ServiceCollection(); 32var services = new ServiceCollection();
RouterMiddlewareTest.cs (1)
20var services = new ServiceCollection();
RouteTest.cs (3)
653var services = new ServiceCollection(); 1515var services = new ServiceCollection(); 1760var services = new ServiceCollection();
RoutingServiceCollectionExtensionsTests.cs (2)
31var services = new ServiceCollection(); 66var services = new ServiceCollection();
TemplateParserDefaultValuesTests.cs (1)
128var services = new ServiceCollection();
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (4)
AddressBinderTests.cs (1)
293var services = new ServiceCollection();
KestrelServerOptionsTests.cs (1)
83var serviceCollection = new ServiceCollection();
KestrelServerTests.cs (2)
788var serviceCollection = new ServiceCollection(); 927var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.SignalR.Microbenchmarks (2)
DefaultHubActivatorBenchmark.cs (1)
17var services = new ServiceCollection();
DefaultHubDispatcherBenchmark.cs (1)
25var serviceCollection = new ServiceCollection();
Microsoft.AspNetCore.SignalR.StackExchangeRedis.Tests (1)
RedisDependencyInjectionExtensionsTests.cs (1)
23var services = new ServiceCollection();
Microsoft.AspNetCore.SignalR.Tests (10)
AddSignalRTests.cs (7)
25var serviceCollection = new ServiceCollection(); 54var serviceCollection = new ServiceCollection(); 77var serviceCollection = new ServiceCollection(); 96var serviceCollection = new ServiceCollection(); 122var serviceCollection = new ServiceCollection(); 136var serviceCollection = new ServiceCollection(); 172var serviceCollection = new ServiceCollection();
HubConnectionHandlerTestUtils\Utils.cs (3)
56public static IServiceProvider CreateServiceProvider(Action<ServiceCollection> addServices = null, ILoggerFactory loggerFactory = null) 58var services = new ServiceCollection(); 75public static Connections.ConnectionHandler GetHubConnectionHandler(Type hubType, ILoggerFactory loggerFactory = null, Action<ServiceCollection> addServices = null)
Microsoft.AspNetCore.SpaServices.Extensions.Tests (1)
SpaServicesExtensionsTests.cs (1)
58var services = new ServiceCollection();
Microsoft.AspNetCore.TestHost.Tests (1)
TestServerTests.cs (1)
403var services = new ServiceCollection();
Microsoft.AspNetCore.WebSockets.Tests (1)
AddWebSocketsTests.cs (1)
15var serviceCollection = new ServiceCollection();
Microsoft.DotNet.Build.Tasks.Feed.Tests (3)
GenerateBuildManifestTests.cs (1)
24var collection = new ServiceCollection();
PublishArtifactsInManifestTests.cs (1)
266var collection = new ServiceCollection();
PushToBuildStorageTests.cs (1)
561var collection = new ServiceCollection();
Microsoft.DotNet.Helix.Sdk.Tests (9)
CreateXHarnessAndroidWorkItemsTests.cs (2)
203var collection = new ServiceCollection(); 255var collection = new ServiceCollection();
CreateXHarnessAppleWorkItemsTests.cs (2)
262var collection = new ServiceCollection(); 328var collection = new ServiceCollection();
FindDotNetCliPackageTests.cs (1)
225var collection = new ServiceCollection();
InstallDotNetToolTests.cs (4)
242var collection1 = new ServiceCollection(); 247var collection2 = new ServiceCollection(); 321var collection = new ServiceCollection(); 339var collection = new ServiceCollection();
Microsoft.DotNet.Internal.DependencyInjection.Testing (4)
DependencyInjectionValidation.cs (4)
34Action<ServiceCollection> register, 44var services = new ServiceCollection(); 92ServiceCollection services, 127ServiceCollection services,
Microsoft.DotNet.VersionTools.Tasks.Tests (2)
LocalUpdatePublishedVersionsTests.cs (1)
19var collection = new ServiceCollection();
UpdatePublishedVersionsTests.cs (1)
19var collection = new ServiceCollection();
Microsoft.Extensions.AI.Tests (3)
ChatCompletion\FunctionInvokingChatClientTests.cs (1)
418ServiceCollection c = new();
ChatCompletion\LoggingChatClientTests.cs (1)
32ServiceCollection c = new();
Embeddings\LoggingEmbeddingGeneratorTests.cs (1)
31ServiceCollection c = new();
Microsoft.Extensions.AmbientMetadata.Application.Tests (1)
ApplicationMetadataExtensionsTests.cs (1)
35var serviceCollection = new ServiceCollection();
Microsoft.Extensions.AsyncState.Tests (1)
AsyncContextServiceCollectionExtensionsTests.cs (1)
23var services = new ServiceCollection();
Microsoft.Extensions.Caching.Hybrid.Tests (27)
BufferReleaseTests.cs (2)
17private static ServiceProvider GetDefaultCache(out DefaultHybridCache cache, Action<ServiceCollection>? config = null) 19var services = new ServiceCollection();
DistributedCacheTests.cs (1)
46var services = new ServiceCollection();
FunctionalTests.cs (2)
11private static ServiceProvider GetDefaultCache(out DefaultHybridCache cache, Action<ServiceCollection>? config = null) 13var services = new ServiceCollection();
L2Tests.cs (1)
36var services = new ServiceCollection();
RedisTests.cs (1)
45var services = new ServiceCollection();
SampleUsage.cs (4)
16var services = new ServiceCollection(); 36var services = new ServiceCollection(); 56var services = new ServiceCollection(); 76var services = new ServiceCollection();
ServiceConstructionTests.cs (10)
28var services = new ServiceCollection(); 37var services = new ServiceCollection(); 89var services = new ServiceCollection(); 102var services = new ServiceCollection(); 115var services = new ServiceCollection(); 129var services = new ServiceCollection(); 141var services = new ServiceCollection(); 155var services = new ServiceCollection(); 175var services = new ServiceCollection(); 189var services = new ServiceCollection();
SizeTests.cs (4)
32var services = new ServiceCollection(); 101var services = new ServiceCollection(); 154var services = new ServiceCollection(); 216var services = new ServiceCollection();
StampedeTests.cs (1)
17var services = new ServiceCollection();
UnreliableL2Tests.cs (1)
126var services = new ServiceCollection();
Microsoft.Extensions.Caching.MicroBenchmarks (1)
DistributedCacheBenchmarks.cs (1)
51var services = new ServiceCollection();
Microsoft.Extensions.Caching.SqlServer.Tests (3)
SqlServerCacheServicesExtensionsTest.cs (3)
18var services = new ServiceCollection(); 34var services = new ServiceCollection(); 58var services = new ServiceCollection();
Microsoft.Extensions.Caching.StackExchangeRedis.Tests (6)
CacheServiceExtensionsTests.cs (6)
20var services = new ServiceCollection(); 36var services = new ServiceCollection(); 55var services = new ServiceCollection(); 64var services = new ServiceCollection(); 80var services = new ServiceCollection(); 97var services = new ServiceCollection();
Microsoft.Extensions.DependencyInjection (1)
Properties\TypeForwards.cs (1)
4[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(Microsoft.Extensions.DependencyInjection.ServiceCollection))]
Microsoft.Extensions.DependencyInjection.Abstractions (2)
ServiceCollection.cs (2)
138private readonly ServiceCollection _services; 140public ServiceCollectionDebugView(ServiceCollection services)
Microsoft.Extensions.Diagnostics.HealthChecks.Common.Tests (9)
ApplicationLifecycleHealthChecksExtensionsTests.cs (3)
19var serviceCollection = new ServiceCollection(); 29var serviceCollection = new ServiceCollection(); 39var serviceCollection = new ServiceCollection();
ManualHealthCheckExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 26var serviceCollection = new ServiceCollection(); 35var serviceCollection = new ServiceCollection();
TelemetryHealthChecksPublisherExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 34var serviceCollection = new ServiceCollection(); 54var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Diagnostics.HealthChecks.Tests (7)
DefaultHealthCheckServiceTest.cs (2)
30var serviceCollection = new ServiceCollection(); 628var services = new ServiceCollection();
DependencyInjection\HealthChecksBuilderTest.cs (2)
205var services = new ServiceCollection(); 225var services = new ServiceCollection();
DependencyInjection\ServiceCollectionExtensionsTest.cs (2)
19var services = new ServiceCollection(); 49var services = new ServiceCollection();
HealthCheckPublisherHostedServiceTest.cs (1)
742var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (1)
ResourceMonitoringExtensionsTests.cs (1)
23var services = new ServiceCollection();
Microsoft.Extensions.Hosting (2)
HostApplicationBuilder.cs (1)
23private readonly ServiceCollection _serviceCollection = new();
HostBuilder.cs (1)
336var services = new ServiceCollection();
Microsoft.Extensions.Http.Diagnostics.PerformanceTests (6)
HttpClientFactory.cs (6)
16var services = new ServiceCollection(); 40var services = new ServiceCollection(); 63var services = new ServiceCollection(); 90var services = new ServiceCollection(); 113var services = new ServiceCollection(); 136var services = new ServiceCollection();
Microsoft.Extensions.Http.Diagnostics.Tests (8)
Logging\HttpClientLoggingExtensionsTest.cs (5)
82var services = new ServiceCollection(); 105var services = new ServiceCollection(); 128var services = new ServiceCollection(); 159var services = new ServiceCollection(); 268var services = new ServiceCollection();
Logging\HttpRequestReaderTest.cs (1)
581var services = new ServiceCollection();
TelemetryCommonExtensionsTests.cs (2)
63var serviceCollection = new ServiceCollection(); 87var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Http.Polly.Tests (14)
DependencyInjection\PollyHttpClientBuilderExtensionsTest.cs (14)
41var serviceCollection = new ServiceCollection(); 76var serviceCollection = new ServiceCollection(); 114var serviceCollection = new ServiceCollection(); 152var serviceCollection = new ServiceCollection(); 190var serviceCollection = new ServiceCollection(); 252var serviceCollection = new ServiceCollection(); 297var serviceCollection = new ServiceCollection(); 332var serviceCollection = new ServiceCollection(); 402var serviceCollection = new ServiceCollection(); 446var serviceCollection = new ServiceCollection(); 463var serviceCollection = new ServiceCollection(); 480var serviceCollection = new ServiceCollection(); 501var serviceCollection = new ServiceCollection(); 530var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Http.Resilience.PerformanceTests (3)
HttpClientFactory.cs (1)
36var services = new ServiceCollection();
RetryBenchmark.cs (1)
32var services = new ServiceCollection();
StandardResilienceBenchmark.cs (1)
32var services = new ServiceCollection();
Microsoft.Extensions.Http.Resilience.Tests (6)
Hedging\StandardHedgingTests.cs (1)
308var services = new ServiceCollection();
Resilience\HttpClientBuilderExtensionsTests.Resilience.cs (5)
28var services = new ServiceCollection(); 46var services = new ServiceCollection(); 66var services = new ServiceCollection(); 89var services = new ServiceCollection(); 169var services = new ServiceCollection();
Microsoft.Extensions.Localization.Tests (2)
LocalizationServiceCollectionExtensionsTest.cs (2)
17var collection = new ServiceCollection(); 31var collection = new ServiceCollection();
Microsoft.Extensions.Logging (1)
LoggerFactory.cs (1)
113var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Resilience.PerformanceTests (1)
ResilienceEnrichmentBenchmark.cs (1)
40var services = new ServiceCollection();
Microsoft.Extensions.ServiceDiscovery.Tests (1)
ServiceEndpointResolverTests.cs (1)
59var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Telemetry.Abstractions.Tests (2)
Enrichment\EnricherExtensionsTests.cs (2)
36var services = new ServiceCollection(); 55var services = new ServiceCollection();
Microsoft.Extensions.Telemetry.PerformanceTests (1)
ExtendedLoggerBench.cs (1)
57var serviceCollection = new ServiceCollection();
Microsoft.Extensions.Telemetry.Tests (2)
Latency\LatencyConsoleExtensionsTests.cs (1)
19var s = new ServiceCollection();
Logging\Utils.cs (1)
14var serviceCollection = new ServiceCollection();
Microsoft.Extensions.WebEncoders.Tests (3)
EncoderServiceCollectionExtensionsTests.cs (3)
17var serviceCollection = new ServiceCollection(); 36var serviceCollection = new ServiceCollection(); 65var serviceCollection = new ServiceCollection();
Microsoft.Gen.Logging.Generated.Tests (1)
Utils.cs (1)
71var serviceCollection = new ServiceCollection();
PhotinoTestApp (1)
Program.cs (1)
16var serviceCollection = new ServiceCollection();
Wasm.Performance.ConsoleHost (1)
Scenarios\ComponentRenderingScenarioBase.cs (1)
26var serviceCollection = new ServiceCollection();