1.24.10
Fixed
- When the
TestContextwas disposed, it disposed of all services via the service provider. However, if there were ongoing renders happening, this could cause inconsistent state in the render tree, since theTestRenderercould try to access the service provider to instantiate components.
This release changes the dispose phase such that the renderer gets disposed first, then the service provider. The disposal of any services that implementIAsyncDisposableis now also awaited. Fixed by @egil and @linkdotnet. Reported by @BenSchoen in #1227.
Added
-
Support for custom service provider factories (
IServiceProviderFactory<TContainerBuilder>). This enables the use of Autofac and other frameworks for dependency injection like on real-world ASP.NET Core / Blazor projects. By @inf9144. -
Ability to raise the
oncancelandoncloseevent, that was introduced with .NET 8.