ITestApplicationLifecycleCallbacks Interface
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Caution
Use ITestHostApplicationLifetime instead. This interface will be removed in v2.
Represents the interface for test application lifecycle callbacks.
public interface ITestApplicationLifecycleCallbacks : Microsoft.Testing.Platform.Extensions.TestHost.ITestHostExtension
[System.Obsolete("Use ITestHostApplicationLifetime instead. This interface will be removed in v2.")]
public interface ITestApplicationLifecycleCallbacks : Microsoft.Testing.Platform.Extensions.TestHost.ITestHostExtension
type ITestApplicationLifecycleCallbacks = interface
interface ITestHostExtension
interface IExtension
[<System.Obsolete("Use ITestHostApplicationLifetime instead. This interface will be removed in v2.")>]
type ITestApplicationLifecycleCallbacks = interface
interface ITestHostExtension
interface IExtension
Public Interface ITestApplicationLifecycleCallbacks
Implements ITestHostExtension
- Derived
- Attributes
- Implements
Properties
| Name | Description |
|---|---|
| Description |
Gets the description of the extension. (Inherited from IExtension) |
| DisplayName |
Gets the display name of the extension. (Inherited from IExtension) |
| Uid |
Gets the unique identifier for the extension. (Inherited from IExtension) |
| Version |
Gets the version of the extension (ideally semantic version). (Inherited from IExtension) |
Methods
| Name | Description |
|---|---|
| AfterRunAsync(Int32, CancellationToken) |
Executes after the test run. |
| BeforeRunAsync(CancellationToken) |
Executes before the test run. |
| IsEnabledAsync() |
Controls whether the extension is enabled or not. This is useful for extensions that are always registered but only enabled when certain conditions are met. For example, an extension that would want to be run only when its associated command line option is provided by the user. (Inherited from IExtension) |