Class ManagedWebHostFixture
- Assembly
- Codebelt.Extensions.Xunit.Hosting.AspNetCore.dll
Provides a default implementation of the IWebHostFixture interface.
public class ManagedWebHostFixture : ManagedHostFixture, IAsyncLifetime, IWebHostFixture, IGenericHostFixture, IHostFixture, IConfigurationTest, IEnvironmentTest, IDisposable, IAsyncDisposable, IPipelineTest
- Inheritance
-
ManagedWebHostFixture
- Implements
-
IAsyncLifetime
- Derived
- Inherited Members
- Extension Methods
Constructors
ManagedWebHostFixture()
Initializes a new instance of the ManagedWebHostFixture class.
public ManagedWebHostFixture()
Properties
Application
Gets the Microsoft.AspNetCore.Builder.IApplicationBuilder initialized by the IHost.
public IApplicationBuilder Application { get; protected set; }
Property Value
- IApplicationBuilder
The Microsoft.AspNetCore.Builder.IApplicationBuilder initialized by the IHost.
ConfigureApplicationCallback
Gets or sets the delegate that configures the HTTP request pipeline.
public Action<IApplicationBuilder> ConfigureApplicationCallback { get; set; }
Property Value
- Action<IApplicationBuilder>
The delegate that configures the HTTP request pipeline.
Methods
ConfigureHost(Test)
Creates and configures the Microsoft.AspNetCore.Hosting.IWebHost of this instance.
public override void ConfigureHost(Test hostTest)
Parameters
hostTest
TestThe object that inherits from WebHostTest<T>.
Remarks
hostTest
was added to support those cases where the caller is required in the host configuration.
Exceptions
- ArgumentNullException
hostTest
is null.- ArgumentOutOfRangeException
hostTest
is not assignable from WebHostTest<T>.