Browse Source

Configure the OWIN server integration test server to use ITestOutputHelper

pull/1010/head
Kévin Chalet 6 years ago
parent
commit
08d51aaa96
  1. 5
      test/OpenIddict.Server.AspNetCore.IntegrationTests/OpenIddictServerAspNetCoreIntegrationTests.cs
  2. 3
      test/OpenIddict.Server.Owin.IntegrationTests/OpenIddictServerOwinIntegrationTests.cs

5
test/OpenIddict.Server.AspNetCore.IntegrationTests/OpenIddictServerAspNetCoreIntegrationTests.cs

@ -454,10 +454,7 @@ namespace OpenIddict.Server.AspNetCore.FunctionalTests
#endif #endif
builder.UseEnvironment("Testing"); builder.UseEnvironment("Testing");
builder.ConfigureLogging(builder => builder.ConfigureLogging(options => options.AddXUnit(OutputHelper));
{
builder.AddXUnit(OutputHelper);
});
builder.ConfigureServices(ConfigureServices); builder.ConfigureServices(ConfigureServices);
builder.ConfigureServices(services => builder.ConfigureServices(services =>

3
test/OpenIddict.Server.Owin.IntegrationTests/OpenIddictServerOwinIntegrationTests.cs

@ -12,6 +12,7 @@ using System.Security.Claims;
using System.Text.Json; using System.Text.Json;
using System.Threading.Tasks; using System.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Microsoft.Owin; using Microsoft.Owin;
using Microsoft.Owin.Security; using Microsoft.Owin.Security;
using Microsoft.Owin.Testing; using Microsoft.Owin.Testing;
@ -328,6 +329,8 @@ namespace OpenIddict.Server.Owin.FunctionalTests
var services = new ServiceCollection(); var services = new ServiceCollection();
ConfigureServices(services); ConfigureServices(services);
services.AddLogging(options => options.AddXUnit(OutputHelper));
services.AddOpenIddict() services.AddOpenIddict()
.AddServer(options => .AddServer(options =>
{ {

Loading…
Cancel
Save