Share via


MefHostingFixture Class

Definition

Provides VS MEF hosting facilities for unit tests as an xunit fixture.

public class MefHostingFixture : Microsoft.VisualStudio.Sdk.TestFramework.MefHosting
type MefHostingFixture = class
    inherit MefHosting
Public Class MefHostingFixture
Inherits MefHosting
Inheritance
MefHostingFixture

Remarks

This class is equivalent to MefHosting except that it only offers one public constructor, as is required of an xunit fixture.

Constructors

MefHostingFixture()

Initializes a new instance of the MefHostingFixture class where all assemblies in the test project's output directory are included in the MEF catalog.

Methods

CreateExportProviderAsync()

Creates a new MEF container, initialized with all the assemblies specified in the constructor.

(Inherited from MefHosting)
GetCatalogAsync()

Gets the ComposableCatalog that backs this MEF service.

(Inherited from MefHosting)
GetConfigurationAsync()

Gets the CompositionConfiguration that backs this MEF service.

(Inherited from MefHosting)

Applies to