Shirubasoft.Aspire.ModularAppHosts.Testing 13.2.0

dotnet add package Shirubasoft.Aspire.ModularAppHosts.Testing --version 13.2.0
                    
NuGet\Install-Package Shirubasoft.Aspire.ModularAppHosts.Testing -Version 13.2.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Shirubasoft.Aspire.ModularAppHosts.Testing" Version="13.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Shirubasoft.Aspire.ModularAppHosts.Testing" Version="13.2.0" />
                    
Directory.Packages.props
<PackageReference Include="Shirubasoft.Aspire.ModularAppHosts.Testing" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Shirubasoft.Aspire.ModularAppHosts.Testing --version 13.2.0
                    
#r "nuget: Shirubasoft.Aspire.ModularAppHosts.Testing, 13.2.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Shirubasoft.Aspire.ModularAppHosts.Testing@13.2.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Shirubasoft.Aspire.ModularAppHosts.Testing&version=13.2.0
                    
Install as a Cake Addin
#tool nuget:?package=Shirubasoft.Aspire.ModularAppHosts.Testing&version=13.2.0
                    
Install as a Cake Tool

Shirubasoft.Aspire.ModularAppHosts.Testing

Run the same Aspire E2E test suite against an in-process AppHost or an Aspire-managed Docker Compose deployment. The package implements Compose mode through IDistributedApplicationTestingBuilder and keeps testing and Docker dependencies out of regular AppHosts.

dotnet add package Shirubasoft.Aspire.ModularAppHosts.Testing

Export the endpoints and values an external deployment test needs:

compose
    .WithTestEndpoint(
        "catalog-api",
        catalog.Api.GetEndpoint("http"),
        healthCheckPath: "/health")
    .WithTestValue("Parameters:api-key", apiKey.Resource)
    .WithTestConnectionString("catalog", catalogDatabase);

Then pass the selected mode into a shared scenario:

static async Task RunScenarioAsync(string mode)
{
    await using IDistributedApplicationTestingBuilder builder = mode switch
    {
        "apphost" => await DistributedApplicationTestingBuilder
            .CreateAsync<Projects.EShop_E2E_AppHost>(),
        "compose" => await DockerComposeDeploymentTestingBuilder
            .DeployAsync<Projects.EShop_E2E_AppHost>(),
        _ => throw new InvalidOperationException($"Unknown E2E mode '{mode}'.")
    };

    await using var app = await builder.BuildAsync();
    await app.StartAsync();
    await app.ResourceNotifications.WaitForResourceHealthyAsync("catalog-api");
    // Run shared assertions.
}

DeployAsync deploys through Aspire, imports the resolved endpoints and configuration, and destroys the deployment when the builder is disposed. It prefers a restored local Aspire tool manifest, retries detected host-port bind conflicts once, and allows both behaviors to be overridden through DockerComposeDeploymentOptions. Create and CreateFromEnvironment import a deployment owned by another system.

Endpoint names and multiple endpoints per resource are preserved, so the same CreateHttpClient(resourceName, endpointName) calls work in both modes. Pass DockerComposeDeploymentOptions when CI needs an explicit environment, output path, Aspire CLI path, or deploy/cleanup timeouts. Aspire CLI output is streamed during deployment and cleanup.

Read the E2E testing guide for endpoint requirements, lifecycle options, and CI configuration. The repository also includes a complete catalog-and-orders sample.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
13.2.0 0 8/18/2026
13.1.0 92 8/15/2026
13.0.0 94 8/14/2026
12.0.1 82 8/14/2026
12.0.0 84 8/14/2026
11.0.0 79 8/13/2026
10.0.1 83 8/12/2026
10.0.0 85 8/12/2026
9.0.0 80 8/11/2026
8.1.0 87 8/11/2026
8.0.0 78 8/11/2026
7.0.0 81 8/10/2026
6.0.0 90 8/8/2026
5.0.0 85 8/7/2026
4.3.0 87 8/7/2026
4.2.0 85 8/6/2026
4.1.0 92 8/6/2026
4.0.0 91 8/5/2026
3.0.0 85 8/5/2026
2.0.0 88 8/5/2026
Loading failed