Is there an existing issue for this?
Describe the bug
ObjectDisposedException thrown when trying to use the WebApplicationClient targeting SDK 6.0.201.
When reverting to SDK 6.0.200, the issue goes away.
Expected Behavior
ObjectDisposedException should not be thrown.
Steps To Reproduce
Write any test that calls WebApplicationFactory.CreateClient()
Exceptions (if any)
System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'ConfigurationManager'.
at Microsoft.Extensions.Configuration.ReferenceCountedProviderManager.AddProvider(IConfigurationProvider provider)
at Microsoft.Extensions.Configuration.ConfigurationManager.AddSource(IConfigurationSource source)
at Microsoft.Extensions.Configuration.ConfigurationManager.Microsoft.Extensions.Configuration.IConfigurationBuilder.Add(IConfigurationSource source)
at Microsoft.AspNetCore.Builder.WebApplicationBuilder.<>c__DisplayClass25_0.<Build>b__2(HostBuilderContext context, IServiceCollection services)
at Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()
at Microsoft.Extensions.Hosting.HostBuilder.Build()
at Microsoft.AspNetCore.Builder.WebApplicationBuilder.Build()
at Program.<Main>$(String[] args) in D:\GIT\Whds.Packing.App\src\Whds.Packing.StateMachine\Program.cs:line 53
.NET Version
6.0.201
Anything else?
No response
Is there an existing issue for this?
Describe the bug
ObjectDisposedExceptionthrown when trying to use theWebApplicationClienttargeting SDK 6.0.201.When reverting to SDK 6.0.200, the issue goes away.
Expected Behavior
ObjectDisposedExceptionshould not be thrown.Steps To Reproduce
Write any test that calls
WebApplicationFactory.CreateClient()Exceptions (if any)
.NET Version
6.0.201
Anything else?
No response