Show / Hide Table of Contents

Class WebAppComponent<TEntryPoint>

A component for hosting a web application via Microsoft.AspNetCore.Hosting.IWebHost.

Inheritance
System.Object
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>
WebAppComponent<TEntryPoint>
Implements
System.IDisposable
System.IAsyncDisposable
IAccelergreatComponent
IAsyncDisposable
Inherited Members
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.WithWebHostBuilder(System.Action<Microsoft.AspNetCore.Hosting.IWebHostBuilder>)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.GetTestAssemblies()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateHostBuilder()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateWebHostBuilder()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateServer(Microsoft.AspNetCore.Hosting.IWebHostBuilder)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateHost(Microsoft.Extensions.Hosting.IHostBuilder)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateClient()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateClient(Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactoryClientOptions)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateDefaultClient(System.Net.Http.DelegatingHandler[])
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.ConfigureClient(System.Net.Http.HttpClient)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.CreateDefaultClient(System.Uri, System.Net.Http.DelegatingHandler[])
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.Dispose()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.Dispose(System.Boolean)
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.DisposeAsync()
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.Server
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.Services
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.Factories
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.ClientOptions
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Accelergreat.Web
Assembly: Accelergreat.Web.dll
Syntax
public class WebAppComponent<TEntryPoint> : WebApplicationFactory<TEntryPoint>, IDisposable, IAsyncDisposable, IAccelergreatComponent where TEntryPoint : class
Type Parameters
Name Description
TEntryPoint

The Startup class of the web application to be hosted.

Methods

BuildConfiguration(IConfigurationBuilder, IReadOnlyAccelergreatEnvironmentPipelineData)

Override this method to add configuration values to the configurationBuilder.

Declaration
protected virtual void BuildConfiguration(IConfigurationBuilder configurationBuilder, IReadOnlyAccelergreatEnvironmentPipelineData accelergreatEnvironmentPipelineData)
Parameters
Type Name Description
Microsoft.Extensions.Configuration.IConfigurationBuilder configurationBuilder
IReadOnlyAccelergreatEnvironmentPipelineData accelergreatEnvironmentPipelineData

See AccelergreatEnvironmentPipelineDataKeys for pre-defined keys.

ConfigureWebHost(IWebHostBuilder)

Declaration
protected sealed override void ConfigureWebHost(IWebHostBuilder builder)
Parameters
Type Name Description
Microsoft.AspNetCore.Hosting.IWebHostBuilder builder
Overrides
Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory<TEntryPoint>.ConfigureWebHost(Microsoft.AspNetCore.Hosting.IWebHostBuilder)

ConfigureWebHost(IWebHostBuilder, IConfiguration, IReadOnlyAccelergreatEnvironmentPipelineData)

Override this method to configure the Microsoft.AspNetCore.Hosting.IWebHostBuilder.

The configuration is automatically applied with Microsoft.AspNetCore.Hosting.HostingAbstractionsWebHostBuilderExtensions.UseConfiguration(Microsoft.AspNetCore.Hosting.IWebHostBuilder,Microsoft.Extensions.Configuration.IConfiguration).

Declaration
protected virtual void ConfigureWebHost(IWebHostBuilder builder, IConfiguration configuration, IReadOnlyAccelergreatEnvironmentPipelineData accelergreatEnvironmentPipelineData)
Parameters
Type Name Description
Microsoft.AspNetCore.Hosting.IWebHostBuilder builder
Microsoft.Extensions.Configuration.IConfiguration configuration
IReadOnlyAccelergreatEnvironmentPipelineData accelergreatEnvironmentPipelineData

See AccelergreatEnvironmentPipelineDataKeys for pre-defined keys.

OnWebAppInitializedAsync()

Called after the web app has been started.

Declaration
protected virtual Task OnWebAppInitializedAsync()
Returns
Type Description
Task

OnWebAppResetAsync()

Called after the web app has been reset.

Declaration
protected virtual Task OnWebAppResetAsync()
Returns
Type Description
Task

Implements

System.IDisposable
System.IAsyncDisposable
IAccelergreatComponent
IAsyncDisposable
In This Article
Back to top Copyright © Nanogunn Ltd.