ProtoTest.Aspire 1.1.9

dotnet add package ProtoTest.Aspire --version 1.1.9
                    
NuGet\Install-Package ProtoTest.Aspire -Version 1.1.9
                    
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="ProtoTest.Aspire" Version="1.1.9" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ProtoTest.Aspire" Version="1.1.9" />
                    
Directory.Packages.props
<PackageReference Include="ProtoTest.Aspire" />
                    
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 ProtoTest.Aspire --version 1.1.9
                    
#r "nuget: ProtoTest.Aspire, 1.1.9"
                    
#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 ProtoTest.Aspire@1.1.9
                    
#: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=ProtoTest.Aspire&version=1.1.9
                    
Install as a Cake Addin
#tool nuget:?package=ProtoTest.Aspire&version=1.1.9
                    
Install as a Cake Tool

ProtoTest.Aspire

Preview: the surface can change before 1.2.

Runs an Aspire AppHost with the suite: it starts with the run, each declared resource becomes an application target, and the run releases it.

dotnet add package ProtoTest.Aspire

The package targets net8.0, net9.0 and net10.0; the suite's AppHost leg runs on net10.0.

Includes

  • Registration through AddAspireAppHost<TEntryPoint>(); the suite runs the AppHost's own entry point through the Aspire testing host. The AppHost serves only when selected: the global ProtoTest:Aspire:Enabled or a resource's own ProtoTest:Aspire:Resources:{resource}:Enabled.
  • Run-scoped lifetime: started after the infrastructure registered before it, stopped with the run.
  • Each selected resource's endpoint published as ProtoTest:Applications:{resource}:BaseUrl, so the application's clients and AddHttpReadiness resolve that one address.
  • Chain providers: UseAspireResource<TEntryPoint>("resource") on an application publishes the resource's endpoint under its derived BaseUrl, and on an infrastructure target publishes the resource's connection string under every declared key. The provider serves under the same selection keys; a configured provider earlier in the chain wins. The resource's key selects only its targets, so "AppHost infrastructure with an in-process application" and its reverse are expressible.
  • The run's configuration and the settings earlier infrastructure published travel to the AppHost as command-line arguments (the options' Set values last), so the AppHost's own graph reads the addresses the suite resolved.
  • ProtoAspireOptions.MapConnectionString(resource, key) fills a key no target declares.
  • A run that configures every declared resource's key skips the AppHost even when selected and points at that environment instead; with only some configured, it starts and publishes only the selected missing keys, so a configured address is never masked.
  • Per-test address lookup through Proto.Context.AspireResource("api").
  • The aspire capability and a run entity per AppHost, with the published endpoints as evidence.

Limits

  • net8.0/net9.0/net10.0 package assets; the suite's AppHost leg is net10.0, because DCP launches AddProject resources with dotnet run and cannot choose a target framework for a multi-targeted project.
  • Closed box: no per-test service substitution, no in-process assertions. White-box worker tests use ProtoTest.Hosting; topology runs use this package.
  • One AppHost instance per run; the run's state is shared between tests.
  • Without either selection key the AppHost never starts and resolution falls through to the chain's other providers.
  • The AppHost receives the run's configuration and settings as arguments; bridging them into its projects (AddConnectionString, WithEnvironment) stays the AppHost project's code, because only it knows its graph.
  • A connection-string resource has no endpoint: ProtoAspireOptions.MapConnectionString replaces its endpoint publish, and a resource that exposes neither fails the AppHost start naming it.
  • The AppHost needs Aspire's orchestration binaries (DCP, dashboard) at runtime; they restore with the AppHost SDK from NuGet. A suite that must run without them catches ProtoAspireUnavailableException at startup and skips with its message.
  • Start does not wait for readiness; register AddHttpReadiness after the AppHost for the HTTP resources tests call.

Learn more

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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
1.1.9 81 10/10/2026
1.1.8 103 10/10/2026
1.1.7 94 10/9/2026
1.1.6 148 10/4/2026
1.1.5 105 10/3/2026
1.1.4 93 10/3/2026
1.1.3 95 10/3/2026
1.1.2 93 10/3/2026
1.1.1 97 10/2/2026
1.1.0 112 10/2/2026