Skip to content

Commit 7d330c3

Browse files
committed
Try another way
1 parent 58491e7 commit 7d330c3

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

test/TestBuildingBlocks/IntegrationTestContext.cs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,18 @@ protected override IHostBuilder CreateHostBuilder()
173173
webBuilder.ConfigureServices(services => _configureServices?.Invoke(services));
174174
webBuilder.UseStartup<TStartup>();
175175
})
176-
.ConfigureLogging(options => _loggingConfiguration?.Invoke(options));
176+
.ConfigureLogging(options =>
177+
{
178+
if (_loggingConfiguration != null)
179+
{
180+
_loggingConfiguration.Invoke(options);
181+
}
182+
else
183+
{
184+
options.SetMinimumLevel(LogLevel.Warning);
185+
options.ClearProviders();
186+
}
187+
});
177188

178189
// @formatter:wrap_before_first_method_call restore
179190
// @formatter:wrap_chained_method_calls restore

0 commit comments

Comments
 (0)