dotnet / aspire

Tools, templates, and packages to accelerate building observable, production-ready apps
https://learn.microsoft.com/dotnet/aspire
MIT License
3.93k stars 480 forks source link

The <DcpPath> property doesn't work in test projects #6565

Open DamianEdwards opened 3 weeks ago

DamianEdwards commented 3 weeks ago

Using the <DcpPath> property to override the directory to load dcp from doesn't work in tests using Asprie.Hosting.Testing, whether the property is set in the source app host project .csproj file, or the test project's .csproj file.

dbreshears commented 2 weeks ago

@DamianEdwards I was able to make this work by setting DCPDir in the app host project HealthChecksUI.csproj, rebuilt it and then ran the single test SamplesIntegrationTests.AppHostTests.AppHostRunsCleanly(appHostPath: "HealthChecksUI.AppHost.dll")

<DCPDir>c:\temp</DCPDir>
DamianEdwards commented 2 weeks ago

Hmmm neither I nor @karolz-ms could get this to work. Slightly confused now 🙃