Ver código fonte

Fix unit test

master
Savorboard 5 anos atrás
pai
commit
7580ae66b2
1 arquivos alterados com 6 adições e 4 exclusões
  1. +6
    -4
      test/DotNetCore.CAP.Test/ConsumerServiceSelectorTest.cs

+ 6
- 4
test/DotNetCore.CAP.Test/ConsumerServiceSelectorTest.cs Ver arquivo

@@ -8,16 +8,18 @@ namespace DotNetCore.CAP.Test
{
public class ConsumerServiceSelectorTest
{
private IServiceProvider _provider;
private readonly IServiceProvider _provider;

public ConsumerServiceSelectorTest()
{
var services = new ServiceCollection();
//services.AddSingleton<IConsumerServiceSelector, DefaultConsumerServiceSelector>();
var services = new ServiceCollection();
ServiceCollectionExtensions.ServiceCollection = services;
services.AddOptions();
services.PostConfigure<CapOptions>(x=>{});
services.AddSingleton<IConsumerServiceSelector, DefaultConsumerServiceSelector>();
services.AddScoped<IFooTest, CandidatesFooTest>();
services.AddScoped<IBarTest, CandidatesBarTest>();
services.AddLogging();
services.AddCap(x => { });
_provider = services.BuildServiceProvider();
}



Carregando…
Cancelar
Salvar