Skip to content

Commit 01f0df1

Browse files
github-actions[bot]eerhardt
authored andcommitted
[release/9.4] External Services with URL Parameter fails to generate manifests (dotnet#10806)
* External Services with URL Parameter fails to generate manifests Need to check for publish mode before calling GetValueAsync on the URL parameter Fix dotnet#10789 * Add test * Fix test to not use Verify --------- Co-authored-by: Eric Erhardt <[email protected]>
1 parent 85f91bf commit 01f0df1

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

tests/Aspire.Hosting.Tests/ExternalServiceTests.cs

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -446,7 +446,20 @@ public async Task ExternalServiceWithParameterPublishManifest()
446446

447447
var manifest = await ManifestUtils.GetManifest(project.Resource);
448448

449-
await Verify(manifest.ToString(), extension: "json");
449+
Assert.Equal(
450+
"""
451+
{
452+
"type": "project.v0",
453+
"path": "testproject",
454+
"env": {
455+
"OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EXCEPTION_LOG_ATTRIBUTES": "true",
456+
"OTEL_DOTNET_EXPERIMENTAL_OTLP_EMIT_EVENT_LOG_ATTRIBUTES": "true",
457+
"OTEL_DOTNET_EXPERIMENTAL_OTLP_RETRY": "in_memory",
458+
"services__external__default__0": "{external-url.value}",
459+
"EXTERNAL_SERVICE": "{external-url.value}"
460+
}
461+
}
462+
""", manifest.ToString());
450463
}
451464

452465
private sealed class TestProject : IProjectMetadata

0 commit comments

Comments
 (0)