30 references to Dependency
Microsoft.AspNetCore.OpenApi.Tests (30)
Transformers\TypeBasedTransformerLifetimeTests.cs (30)
36var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 47Dependency.InstantiationCount = 0; 56Assert.Equal(1, Dependency.InstantiationCount); 62var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 73Dependency.InstantiationCount = 0; 82Assert.Equal(3, Dependency.InstantiationCount); 88var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 99Dependency.InstantiationCount = 0; 108Assert.Equal(3, Dependency.InstantiationCount); 135var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 145Dependency.InstantiationCount = 0; 154Assert.Equal(1, Dependency.InstantiationCount); 160var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 171Dependency.InstantiationCount = 0; 180Assert.Equal(3, Dependency.InstantiationCount); 186var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 197Dependency.InstantiationCount = 0; 206Assert.Equal(3, Dependency.InstantiationCount); 255var serviceCollection = new ServiceCollection().AddSingleton<Dependency>(); 266Dependency.InstantiationCount = 0; 275Assert.Equal(1, Dependency.InstantiationCount); 281var serviceCollection = new ServiceCollection().AddScoped<Dependency>(); 292Dependency.InstantiationCount = 0; 301Assert.Equal(3, Dependency.InstantiationCount); 307var serviceCollection = new ServiceCollection().AddTransient<Dependency>(); 318Dependency.InstantiationCount = 0; 327Assert.Equal(3, Dependency.InstantiationCount); 360public ActivatedSchemaTransformerWithDependency(Dependency dependency) 389public ActivatedOperationTransformerWithDependency(Dependency dependency) 418public ActivatedDocumentTransformerWithDependency(Dependency dependency)