title: .net core 3.0, issue with IClassFixture, "unresolved constructor arguments: ITestOutputHelper output"
body: <p>I made a repo for the issue I have with Integration testing upgrading to .net core 3.0 :
  <a href="https://github.com/ranouf/TestingWithDotNetCore3_0" rel="nofollow noreferrer">https://github.com/ranouf/TestingWithDotNetCore3_0</a></p>
  
  <p>When I launch the test, I have this issue:
  Message: </p>
  
  <blockquote>
    <p>System.AggregateException : One or more errors occurred. (Class fixture type 'MyIntegrationTests.TestServerFixture' had one or more
    unresolved constructor arguments: ITestOutputHelper output) (The
    following constructor parameters did not have matching fixture data:
    TestServerFixture testServerFixture)
        ---- Class fixture type 'MyIntegrationTests.TestServerFixture' had one or more unresolved constructor arguments: ITestOutputHelper output
        ---- The following constructor parameters did not have matching fixture data: TestServerFixture testServerFixture   Stack Trace: 
        ----- Inner Stack Trace #1 (Xunit.Sdk.TestClassException) -----
        ----- Inner Stack Trace #2 (Xunit.Sdk.TestClassException) -----</p>
  </blockquote>
  
  <p>Here is the constructor:</p>
  
  <pre><code>public class WeatherForecastController_Tests : IClassFixture&lt;TestServerFixture&gt;
  {
      public WeatherForecastController_Tests(TestServerFixture testServerFixture, ITestOutputHelper output)
      {
          Client = testServerFixture.Client;
          Output = output;
      }
  </code></pre>
  
  <p>TestStartup:</p>
  
  <pre><code>public class TestStartup : Startup
  {
      public TestStartup(IConfiguration configuration)
          : base(configuration)
      {
  
      }
  
      public override void SetUpDataBase(IServiceCollection services)
      {
          // here is where I use the InMemoryDatabase 
      }
  }
  </code></pre>
  
  <p>TestServerFixture:</p>
  
  <pre><code>public class TestServerFixture : WebApplicationFactory&lt;TestStartup&gt;
  {
      private IHost _host;
      public HttpClient Client { get; }
      public ITestOutputHelper Output { get; }
  
      public TestServerFixture(ITestOutputHelper output)
      {
          Output = output;
          Client = Server.CreateClient();
      }
  
      // never called but this is where i was previously building up the server
      //
      protected override TestServer CreateServer(IWebHostBuilder builder)
      {
          return base.CreateServer(builder);
      }
  
      protected override IHost CreateHost(IHostBuilder builder)
      {
          _host = builder.Build();
  
          using (var scope = _host.Services.CreateScope())
          {
              var services = scope.ServiceProvider;
              InitializeDataBase(services, Output);
          }
  
          _host.Start();
          return _host;
      }
  
      protected override IHostBuilder CreateHostBuilder() =&gt;
          Host.CreateDefaultBuilder()
              .ConfigureLogging((hostingContext, builder) =&gt;
              {
                  builder.Services.AddSingleton&lt;ILoggerProvider&gt;(new XunitLoggerProvider(Output));
              })
              .ConfigureWebHostDefaults(webBuilder =&gt;
              {
                  webBuilder.UseTestServer();
              });
  
      protected override void ConfigureWebHost(IWebHostBuilder builder)
      {
          builder.UseStartup&lt;TestStartup&gt;();
      }
  
      private void InitializeDataBase(IServiceProvider services, ITestOutputHelper output)
      {
          try
          {
              output.WriteLine("Starting the database initialization.");
              //here is where is feed the Test DB
              output.WriteLine("The database initialization has been done.");
          }
          catch (Exception ex)
          {
              output.WriteLine("An error occurred while initialization the database.");
              Console.WriteLine(ex.Message);
          }
      }
  }
  </code></pre>
  
  <p>So clearly, the Iod for TestServerFixture testServerFixture and ITestOutputHelper output doesnt work. How to make it work?</p>