1674 instantiations of JsonObject
AnalyzeCiFailure (24)
AnalyzeCiFailure.TestHost (2)
AnalyzeCiFailure.Tests (92)
AnalyzeCiFailureCollectionTests.cs (18)
654var run = new JsonObject
669["head_repository"] = new JsonObject { ["owner"] = new JsonObject { ["login"] = "fork-owner" } },
684new JsonObject
689["steps"] = new JsonArray(new JsonObject { ["name"] = "Check dependent jobs failed", ["conclusion"] = "failure" }),
691new JsonObject
712new JsonObject { ["name"] = "Set up job", ["status"] = "completed", ["conclusion"] = "success" },
713new JsonObject
727new JsonObject { ["name"] = "Upload E2E diagnostics", ["status"] = "queued", ["conclusion"] = null });
730job["steps"]!.AsArray().Add(new JsonObject { ["name"] = "Post cleanup", ["status"] = "completed", ["conclusion"] = "failure" });
797var artifact = new JsonObject
804["workflow_run"] = new JsonObject { ["id"] = scenario == "wrong-artifact-run" ? 999 : 123, ["head_sha"] = scenario == "wrong-artifact-sha" ? "other-sha" : "failed-sha" },
833artifacts.Add(new JsonObject
837["workflow_run"] = new JsonObject { ["id"] = 123, ["head_sha"] = "failed-sha" },
840pages[0]!["jobs"]!.AsArray().Add(new JsonObject
843["steps"] = new JsonArray(new JsonObject { ["number"] = 1, ["name"] = "Run tests", ["conclusion"] = "failure" }),
856new JsonArray(new JsonObject { ["artifacts"] = artifacts }, new JsonObject { ["artifacts"] = new JsonArray() }).ToJsonString());
AnalyzeCiFailurePublicationTests.cs (21)
132tests.Add(new JsonObject
146var collected = new JsonArray(tests.Select(test => (JsonNode)new JsonObject
205var issue = new JsonObject
212["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
383new JsonObject
388["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
513summary["failed_jobs"]!.AsArray().Add(new JsonObject { ["id"] = 124, ["classification"] = "flaky-test" });
598var observations = new JsonArray(Enumerable.Range(start: 1, count).Select(index => (JsonNode)new JsonObject
605["tests"] = new JsonArray(new JsonObject
612var history = new JsonObject
745new JsonArray(new JsonObject { ["id"] = 123, ["name"] = text }).ToJsonString());
775new JsonArray(new JsonObject
780["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
848new JsonArray(new JsonObject
853["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
902new JsonArray(new JsonObject
908["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
1295((JsonArray)summary["failed_jobs"]!).Add(new JsonObject { ["id"] = 456, ["classification"] = "flaky-test" });
1377var projection = new JsonObject
1465new JsonArray(new JsonObject
1471["labels"] = new JsonArray(new JsonObject { ["name"] = "ci-failure-cause" }),
aspire (100)
Utils\EnvironmentChecker\VsCodeExtensionCheck.cs (1)
221=> new()
Aspire.Cli.EndToEnd.Tests (20)
Aspire.Cli.Tests (186)
Agents\AgentConfigurationTests.cs (11)
161edit.PublishAsync(path, new JsonObject(), CancellationToken.None)).DefaultTimeout();
186edit.PublishAsync(path, new JsonObject(), CancellationToken.None)).DefaultTimeout();
203var config = await edit.ReadObjectForEditAsync(path, CancellationToken.None) ?? new JsonObject();
224var config = await edit.ReadObjectForEditAsync(path, CancellationToken.None) ?? new JsonObject();
254var config = await edit.ReadObjectForEditAsync(path, CancellationToken.None) ?? new JsonObject();
282var config = await edit.ReadObjectForEditAsync(path, CancellationToken.None) ?? new JsonObject();
335path, new JsonObject(), CancellationToken.None)).DefaultTimeout();
373var write = edit.PublishAsync(path, new JsonObject { ["token"] = "replacement" }, CancellationToken.None);
414await edit.PublishAsync(path, new JsonObject { ["token"] = "replacement" },
443await edit.PublishAsync(path, new JsonObject { ["token"] = "replacement" },
495var settings = new JsonObject
Commands\ConfigSourceCommandTests.cs (21)
478return Task.FromResult(("version-1", new JsonObject()));
523git.ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()));
703git.ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()));
757git.ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()));
845git.ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()));
914ReadConfiguration = (_, _) => Task.FromResult(("version-1", new JsonObject
916["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/team" } },
917["docs"] = new JsonObject { ["llmsTxtUrl"] = "https://docs.example/llms.txt" }
1064return Task.FromResult(("version-1", new JsonObject()));
1087ReadConfiguration = (_, _) => Task.FromResult(("version-1", new JsonObject
1089["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = inheritedRepository } }
1193return Task.FromResult(("version-2", new JsonObject()));
1489return Task.FromResult(("version-2", new JsonObject
1491["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/updated" } }
1688ReadConfiguration = (_, _) => Task.FromResult(("version-1", new JsonObject
1690["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/team" } },
1691["sdk"] = new JsonObject { ["version"] = "99.0.0" }
Configuration\ConfigSourceServiceTests.cs (17)
333return Task.FromResult(("version-2", new JsonObject { ["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/updated" } } }));
432return Task.FromResult(("version-2", new JsonObject()));
677ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject
679["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/shared" } }
1029return Task.FromResult(("version-1", new JsonObject()));
1751return Task.FromResult(("version-1", new JsonObject()));
1880return Task.FromResult(("version-1", new JsonObject
1882["skillSources"] = new JsonObject { ["team"] = new JsonObject { ["repository"] = "example/team" } }
1922return ("version-2", new JsonObject());
1946return Task.FromResult(("version-2", new JsonObject()));
1970return Task.FromResult(("version-2", new JsonObject()));
2100git.ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()));
2154ReadConfiguration = (_, _) => Task.FromResult(("version-2", new JsonObject()))
Configuration\ConfigurationHelperTests.cs (26)
34path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None, rejectSymbolicLinks: true));
58path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
93path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
118path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
151await ConfigurationHelper.WriteSettingsFileAtomicallyAsync(path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None);
172await ConfigurationHelper.WriteSettingsFileAtomicallyAsync(path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None);
190ConfigurationHelper.WriteSettingsFileAtomicallyAsync(path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None));
217await ConfigurationHelper.WriteSettingsFileAtomicallyAsync(path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None);
243await ConfigurationHelper.WriteSettingsFileAtomicallyAsync(file.FullName, new JsonObject { ["custom"] = "updated" }, CancellationToken.None);
269path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
310path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
375path, new JsonObject { ["custom"] = "updated" }, CancellationToken.None,
634var settings = new JsonObject
636["appHost"] = new JsonObject { ["path"] = "MyApp.csproj" },
670var settings = new JsonObject
672["appHost"] = new JsonObject { ["path"] = "MyApp.csproj" },
688var settings = new JsonObject
690["appHost"] = new JsonObject { ["path"] = "MyApp.csproj" },
712var settings = new JsonObject
714["appHost"] = new JsonObject { ["path"] = "MyApp.csproj" },
827var nested = new JsonObject();
828var settings = new JsonObject
830["DOCS"] = new JsonObject { ["custom"] = "preserved" },
831["docs"] = new JsonObject { ["api"] = nested }
970var settings = new JsonObject();
973var existing = new JsonObject();
Aspire.Dashboard (3)
Aspire.Dashboard.Tests (10)
Aspire.Hosting (18)
Aspire.Hosting.Azure (17)
Aspire.Hosting.Azure.EntraId.Tests (2)
Aspire.Hosting.Azure.Kubernetes.Tests (49)
AzureKubernetesInfrastructureTests.cs (49)
332stateManager.SetSection("Azure", new JsonObject
337stateManager.SetSection("Azure:Deployments:aks", new JsonObject
339["Outputs"] = new JsonObject
341["id"] = new JsonObject
348["name"] = new JsonObject
354["Scope"] = new JsonObject
360stateManager.SetSection("HelmChart:aks:podinfo", new JsonObject
496stateManager.SetSection("Azure", new JsonObject
501stateManager.SetSection("Azure:Deployments:aks", new JsonObject
503["Outputs"] = new JsonObject
505["id"] = new JsonObject
510["name"] = new JsonObject
516["Scope"] = new JsonObject
522stateManager.SetSection("Helm:aks", new JsonObject
585stateManager.SetSection("Azure", new JsonObject
590stateManager.SetSection("Azure:Deployments:aks", new JsonObject
592["Outputs"] = new JsonObject
594["id"] = new JsonObject
601stateManager.SetSection("Helm:aks", new JsonObject
665stateManager.SetSection("Azure:Deployments:aks", new JsonObject
669stateManager.SetSection("Helm:aks", new JsonObject
710stateManager.SetSection("Azure:Deployments:aks", new JsonObject
712["Outputs"] = new JsonObject
714["id"] = new JsonObject
758stateManager.SetSection("Sentinel", new JsonObject { ["Value"] = "cleared-by-destroy" });
793stateManager.SetSection("Azure:Deployments:aks", new JsonObject
834stateManager.SetSection("Azure:Deployments:aks", new JsonObject
836["Outputs"] = new JsonObject
838["id"] = new JsonObject
889stateManager.SetSection("Azure:Deployments:aks", new JsonObject
891["Outputs"] = new JsonObject
893["id"] = new JsonObject
900stateManager.SetSection("Helm:aks", new JsonObject
957stateManager.SetSection("Azure:Deployments:aks", new JsonObject
959["Outputs"] = new JsonObject
961["id"] = new JsonObject
1029stateManager.SetSection("Azure:Deployments:aks", new JsonObject
1031["Outputs"] = new JsonObject
1033["id"] = new JsonObject
1098stateManager.SetSection("Azure:Deployments:aks", new JsonObject
1100["Outputs"] = new JsonObject
1102["id"] = new JsonObject
1202deploymentStateManager.SetSection("Azure", new JsonObject
1227deploymentStateManager.SetSection("Azure", new JsonObject
1416deploymentStateManager.SetSection("Azure", new JsonObject
1514deploymentStateManager.SetSection("Azure", new JsonObject
1730deploymentStateManager.SetSection("Azure", new JsonObject
1817deploymentStateManager.SetSection("Azure", new JsonObject
1909var azureState = new JsonObject { ["SubscriptionId"] = subscriptionId };
Aspire.Hosting.Azure.Sandboxes (6)
Aspire.Hosting.Azure.Tests (99)
BicepUtilitiesTests.cs (59)
28var scope = new JsonObject();
56var moduleScope = new JsonObject();
77var scope = new JsonObject();
107var scope = new JsonObject();
136var scope = new JsonObject();
169var parameters = new JsonObject();
186var parameters = new JsonObject();
219var parameters = new JsonObject();
250.WithParameter("jsonObj", new JsonObject { ["key"] = "value" })
255var parameters = new JsonObject();
311var parameters = new JsonObject();
330.WithParameter("jsonObj", new JsonObject { ["key"] = "value" });
336.WithParameter("jsonObj", new JsonObject { ["key"] = "value" });
338var parameters0 = new JsonObject();
342var parameters1 = new JsonObject();
363.WithParameter("jsonObj", new JsonObject { ["key"] = "value" });
365var parameters0 = new JsonObject();
369var parameters1 = new JsonObject();
389var parameters0 = new JsonObject();
390var scope0 = new JsonObject();
395var parameters1 = new JsonObject();
396var scope1 = new JsonObject();
417var parameters0 = new JsonObject();
418var scope0 = new JsonObject();
423var parameters1 = new JsonObject();
424var scope1 = new JsonObject();
440var parameters = new JsonObject
442["param1"] = new JsonObject { ["value"] = "value1" }
460var parameters1 = new JsonObject
462["param1"] = new JsonObject { ["value"] = "value1" }
465var parameters2 = new JsonObject
467["param1"] = new JsonObject { ["value"] = "value2" }
485var parameters = new JsonObject
487["param1"] = new JsonObject { ["value"] = "value1" }
490var scope1 = new JsonObject { ["resourceGroup"] = "rg1" };
491var scope2 = new JsonObject { ["resourceGroup"] = "rg2" };
513var parameters1 = new JsonObject
515["param1"] = new JsonObject { ["value"] = value1 }
518var parameters2 = new JsonObject
520["param1"] = new JsonObject { ["value"] = value2 }
548var parameters = new JsonObject();
567var scope = new JsonObject();
582var scope = new JsonObject();
598var scope = new JsonObject();
613var scope = new JsonObject
632var scope = new JsonObject();
646var scope = new JsonObject();
672var stateSection = new DeploymentStateSection("test", new JsonObject
689var parameters = new JsonObject
691["param1"] = new JsonObject { ["value"] = "value1" }
694var stateSection = new DeploymentStateSection("test", new JsonObject
713var legacyParameters = new JsonObject();
719var stateSection = new DeploymentStateSection("test", new JsonObject
726var currentParameters = new JsonObject();
727var currentScope = new JsonObject();
750var parameters = new JsonObject
752[AzureBicepResource.KnownParameters.PrincipalType] = new JsonObject { ["value"] = "User" },
753[AzureBicepResource.KnownParameters.PrincipalId] = new JsonObject { ["value"] = "1234" },
756var stateSection = new DeploymentStateSection("test", new JsonObject
Aspire.Hosting.Azure.WebPubSub (5)
Aspire.Hosting.Blazor (3)
Aspire.Hosting.CodeGeneration.Go (9)
Aspire.Hosting.CodeGeneration.Go.Tests (1)
Aspire.Hosting.CodeGeneration.Java.Tests (1)
Aspire.Hosting.CodeGeneration.TypeScript (10)
Aspire.Hosting.Docker.Tests (1)
Aspire.Hosting.Kubernetes (2)
Aspire.Hosting.Kubernetes.Tests (4)
Aspire.Hosting.Native.Client (2)
Aspire.Hosting.Native.CodeGeneration (7)
Aspire.Hosting.Native.Core.Tests (46)
ApplicationRevisionTests.cs (6)
75("result", new JsonObject { ["status"] = "succeeded", ["message"] = "pong" }))));
367Arguments(("context", writer), ("revision", JsonValue.Create(revision)), ("container", new JsonObject
375Arguments(("context", context.Writer), ("container", new JsonObject
385EnsureSuccess(author.Invoke("setResourceConfiguration", Arguments(("context", resource), ("configuration", new JsonObject
387["properties"] = new JsonArray(new JsonObject { ["name"] = "value", ["value"] = value })
393("result", new JsonObject { ["status"] = status, ["message"] = "" })));
NativeDashboardTests.cs (4)
104("requestId", pending["requestId"]), ("result", new JsonObject { ["status"] = "succeeded", ["message"] = "refreshed" })));
157("context", cache), ("configuration", new JsonObject
159["properties"] = new JsonArray(new JsonObject { ["name"] = "value", ["value"] = "updated" })
173("result", new JsonObject { ["status"] = "succeeded", ["message"] = "" }))));
Aspire.Hosting.Native.Server (24)
Aspire.Hosting.Radius (3)
Aspire.Hosting.RemoteHost (8)
Aspire.Hosting.RemoteHost.Tests (282)
CapabilityDispatcherTests.cs (167)
51dispatcher.Invoke($"Aspire.Hosting.RemoteHost.Tests/{methodName}", new JsonObject { ["callback"] = "callback" });
67dispatcher.Invoke("Aspire.Hosting.RemoteHost.Tests/contextCallbackWithInfiniteTimeout", new JsonObject
69["context"] = new JsonObject { ["$handle"] = handle },
98var result = await dispatcher.InvokeAsync("Aspire.Hosting.Radius/withContainerImage", new JsonObject
100["builder"] = new JsonObject { ["$handle"] = handleId },
201dispatcher.Invoke("Aspire.Hosting/withTerminal", new JsonObject
203["builder"] = new JsonObject { ["$handle"] = handle },
244ResultToReturn = optionsJson is null ? null : new JsonObject { ["p0"] = JsonNode.Parse(optionsJson) }
250var args = new JsonObject { ["builder"] = new JsonObject { ["$handle"] = handleId } };
296ResultToReturn = new JsonObject { ["p0"] = JsonNode.Parse(optionsJson) }
302var args = new JsonObject
304["builder"] = new JsonObject { ["$handle"] = handleId },
373dispatcher.Invoke("test/capability@1", new JsonObject { ["name"] = "test-value" });
484var args = new JsonObject { ["value"] = "hello" };
496var args = new JsonObject { ["required"] = "test" };
508var args = new JsonObject { ["required"] = "test", ["optional"] = "custom" };
520var args = new JsonObject { ["value"] = "test" };
563var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
590var args = new JsonObject { ["context"] = "not-a-handle" };
602var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = "Aspire.Hosting.RemoteHost.Tests/Aspire.Hosting.RemoteHost.Tests.TestContextType:999" } };
619var getArgs = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
626var invokeArgs = new JsonObject { ["cancellationToken"] = tokenResult };
679var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
698var nestedArgs = new JsonObject { ["context"] = new JsonObject { ["$handle"] = nestedHandleId } };
756var args = new JsonObject
758["context"] = new JsonObject { ["$handle"] = handleId },
777var args = new JsonObject
779["context"] = new JsonObject { ["$handle"] = handleId },
796var args = new JsonObject
798["context"] = new JsonObject { ["$handle"] = handleId },
815var args = new JsonObject
817["context"] = new JsonObject { ["$handle"] = handleId }
848var args = new JsonObject
850["context"] = new JsonObject { ["$handle"] = handleId }
866var args = new JsonObject
868["context"] = new JsonObject { ["$handle"] = handleId },
887var args = new JsonObject
889["context"] = new JsonObject { ["$handle"] = handleId },
907var args = new JsonObject
909["context"] = new JsonObject { ["$handle"] = handleId },
923var args = new JsonObject { ["value"] = "value-task" };
964var args = new JsonObject
987var args = new JsonObject
1008var args = new JsonObject
1031var args = new JsonObject
1130new JsonObject { ["callback"] = "background-callback" });
1154new JsonObject { ["callback"] = "background-callback" });
1174var first = Task.Run(() => dispatcher.InvokeAsync(capabilityId, new JsonObject { ["name"] = "first" }));
1177var second = dispatcher.InvokeAsync(capabilityId, new JsonObject { ["name"] = "second" });
1201new JsonObject { ["name"] = "nested" })));
1208new JsonObject { ["callback"] = "reentrant-callback" })).WaitAsync(TimeSpan.FromSeconds(30));
1222var args = new JsonObject
1250var args = new JsonObject { ["value"] = "test" };
1261var args = new JsonObject { ["value"] = "hello" };
1273var args = new JsonObject { ["value"] = "test" };
1287var args = new JsonObject
1302var args = new JsonObject { ["count"] = 3 };
1319var args = new JsonObject
1335var args = new JsonObject { ["value"] = "hello" };
1347var args = new JsonObject { ["value"] = 42 };
1359var args = new JsonObject
1361["value"] = new JsonObject
1377var args = new JsonObject { ["value"] = nameof(TestDispatchEnum.ValueB) };
1389var args = new JsonObject { ["value"] = "/usr/local/lib/redis/modules/redisearch.so" };
1401var args = new JsonObject
1403["value"] = new JsonObject
1427var args = new JsonObject
1429["value"] = new JsonObject { ["$handle"] = handleId }
1446var args = new JsonObject
1448["value"] = new JsonObject { ["$handle"] = handleId }
1467var args = new JsonObject
1469["builder"] = new JsonObject { ["$handle"] = containerHandleId },
1471["value"] = new JsonObject { ["$handle"] = valueHandleId }
1493var args = new JsonObject
1511var args = new JsonObject
1513["value"] = new JsonObject
1556var args = new JsonObject
1558["list"] = new JsonObject { ["$handle"] = listHandle },
1578var args = new JsonObject
1580["list"] = new JsonObject { ["$handle"] = listHandle },
1602var removeArgs = new JsonObject
1604["list"] = new JsonObject { ["$handle"] = listHandle },
1613var lengthArgs = new JsonObject
1615["list"] = new JsonObject { ["$handle"] = listHandle }
1634var args = new JsonObject
1636["list"] = new JsonObject { ["$handle"] = listHandle }
1657var clearArgs = new JsonObject
1659["list"] = new JsonObject { ["$handle"] = listHandle }
1664var lengthArgs = new JsonObject
1666["list"] = new JsonObject { ["$handle"] = listHandle }
1702var args = new JsonObject
1704["dict"] = new JsonObject { ["$handle"] = dictHandle },
1724var args = new JsonObject
1726["dict"] = new JsonObject { ["$handle"] = dictHandle },
1746var args = new JsonObject
1748["dict"] = new JsonObject { ["$handle"] = dictHandle },
1770var removeArgs = new JsonObject
1772["dict"] = new JsonObject { ["$handle"] = dictHandle },
1781var countArgs = new JsonObject
1783["dict"] = new JsonObject { ["$handle"] = dictHandle }
1803var hasArgs = new JsonObject
1805["dict"] = new JsonObject { ["$handle"] = dictHandle },
1814var hasArgs2 = new JsonObject
1816["dict"] = new JsonObject { ["$handle"] = dictHandle },
1836var args = new JsonObject
1838["dict"] = new JsonObject { ["$handle"] = dictHandle }
1861var args = new JsonObject
1863["dict"] = new JsonObject { ["$handle"] = dictHandle }
1885var args = new JsonObject
1887["dict"] = new JsonObject { ["$handle"] = dictHandle }
1905var args = new JsonObject
1907["dict"] = new JsonObject { ["$handle"] = dictHandle }
1922var args = new JsonObject
1939var args = new JsonObject
1956var args = new JsonObject
1973var args = new JsonObject
1990var result = dispatcher.Invoke("Aspire.Hosting.RemoteHost.Tests/acceptOptionalEnum", new JsonObject());
1999var args = new JsonObject
2001["dto"] = new JsonObject
2018var args = new JsonObject
2020["dto"] = new JsonObject
2036var args = new JsonObject
2038["dto"] = new JsonObject
2054var args = new JsonObject();
2076var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
2094var args = new JsonObject
2096["context"] = new JsonObject { ["$handle"] = handleId },
2114var args = new JsonObject
2116["context"] = new JsonObject { ["$handle"] = handleId },
2135var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
2152var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
2167var args = new JsonObject { ["context"] = new JsonObject { ["$handle"] = handleId } };
2187var args = new JsonObject
2189["builder"] = new JsonObject { ["$handle"] = targetHandleId },
2190["source"] = new JsonObject { ["$handle"] = sourceHandleId }
2211var args = new JsonObject
2213["builder"] = new JsonObject { ["$handle"] = builderHandleId }
2233var args = new JsonObject
2235["builder"] = new JsonObject { ["$handle"] = builderHandleId }
2255var args = new JsonObject
2257["builder"] = new JsonObject { ["$handle"] = resourceHandleId }
2276var args = new JsonObject
2278["builder"] = new JsonObject { ["$handle"] = builderHandleId }
2302var args = new JsonObject
2304["context"] = new JsonObject { ["$handle"] = targetHandleId },
2305["value"] = new JsonObject { ["$handle"] = valueHandleId }
2330var args = new JsonObject
2332["builder"] = new JsonObject { ["$handle"] = targetHandleId },
2333["source"] = new JsonObject { ["$handle"] = sourceHandleId }
2350var args = new JsonObject
2352["builder"] = new JsonObject { ["$handle"] = builderHandleId }
2377var args = new JsonObject
2379["builder"] = new JsonObject { ["$handle"] = builderHandleId }
2405var args = new JsonObject
2407["builder"] = new JsonObject { ["$handle"] = handles.Register(new TestResourceBuilder<TestResourceWithProperties>(target), "target-type") }
2491var args = new JsonObject
2493["resource"] = new JsonObject { ["$handle"] = handleId },
ExternalCapabilityRegistryTests.cs (12)
36await registry.TryInvokeAsync("test.external/callback", new JsonObject { ["configure"] = "guest_callback" }, owner);
198await registry.TryInvokeAsync("test.external/callback", new JsonObject { ["configure"] = "guest_callback" }, guest.CallbackInvoker);
202new JsonObject { ["p0"] = "configured" }, TestContext.Current.CancellationToken);
211"test.external/callback", new JsonObject { ["configure"] = "late_callback" }, guest.CallbackInvoker));
270new JsonObject { ["cancellationToken"] = "ct_guest" }, cancellationToken: TestContext.Current.CancellationToken);
313await registry.TryInvokeAsync("test.external/callback", new JsonObject { ["configure"] = "guest_callback" }, guestInvoker);
327"test.external/callback", new JsonObject { ["configure"] = "guest_callback" }, guestInvoker)).Found);
372await registry.TryInvokeAsync("test.external/callback", new JsonObject { ["configure"] = "guest_callback" }, guestInvoker);
637new JsonObject { ["configure"] = "guest_callback" }, new JsonRpcCallbackInvoker(NullLogger<JsonRpcCallbackInvoker>.Instance));
674var firstArgs = new JsonObject { ["name"] = "first", ["configure"] = "guest_callback" };
675var secondArgs = new JsonObject { ["name"] = "second", ["configure"] = "guest_callback" };
726new JsonObject { ["configure"] = "guest_callback" },
KubernetesManifestTests.cs (11)
40var manifestHandle = dispatcher.Invoke("Aspire.Hosting.Kubernetes/addManifest", new JsonObject
51var result = dispatcher.Invoke("Aspire.Hosting.Kubernetes/withField", new JsonObject
98var manifestHandle = dispatcher.Invoke("Aspire.Hosting.Kubernetes/addManifest", new JsonObject
106dispatcher.Invoke("Aspire.Hosting.Kubernetes/withField", new JsonObject
115"object" => new JsonObject { ["label"] = handle },
117"nested" => new JsonObject { ["items"] = new JsonArray(new JsonObject { ["label"] = handle }) },
122"Aspire.Hosting.Kubernetes/withField", new JsonObject
132"Aspire.Hosting.Kubernetes/withField", new JsonObject
151var manifestHandle = dispatcher.Invoke("Aspire.Hosting.Kubernetes/addManifest", new JsonObject
160"Aspire.Hosting.Kubernetes/withField", new JsonObject
Aspire.Hosting.Tests (35)
Aspire.Hosting.Yarp (4)
Aspire.Managed.Tests (9)
ConfigurationSchemaGenerator (13)
dotnet-user-jwts (7)
GenerateTemplateManifest (4)
Infrastructure.Tests (402)
WorkflowScripts\AutoSecWorkflowTests.cs (400)
26var result = await RunHarnessAsync(new JsonObject
29["alerts"] = empty ? new JsonArray() : new JsonArray(new JsonObject
32["dependency"] = new JsonObject
34["package"] = new JsonObject { ["ecosystem"] = "npm", ["name"] = "example" },
37["security_vulnerability"] = new JsonObject
40["first_patched_version"] = new JsonObject { ["identifier"] = "1.2.3" },
42["security_advisory"] = new JsonObject { ["description"] = "synthetic private advisory", ["vulnerabilities"] = new JsonArray() },
44["malware"] = empty ? new JsonArray() : new JsonArray(new JsonObject { ["number"] = 7 }),
73var result = await RunHarnessAsync(new JsonObject { ["mode"] = "collect-alerts", ["failure"] = phase });
104request["failure"] = new JsonObject { ["endpoint"] = endpoint, ["status"] = status };
171request["failure"] = new JsonObject
225scenario["files"] = new JsonArray(new JsonObject
232scenario["contentFailure"] = new JsonObject
252scenario["files"] = new JsonArray("extension/package.json", new JsonObject
261scenario["responses"]!["https://registry.npmjs.org/transitive"] = Response(new JsonObject
263["time"] = new JsonObject { ["4.1.0"] = "2026-09-01T00:00:00Z", ["5.0.0"] = "2026-09-01T00:00:00Z" },
282scenario["files"] = new JsonArray("extension/package.json", new JsonObject { ["filename"] = "extension/yarn.lock", ["status"] = status });
303scenario["files"] = new JsonArray(new JsonObject
377var valid = new JsonObject { ["status"] = "ahead", ["merge_base_commit"] = new JsonObject { ["sha"] = new string('b', 40) } };
513new JsonObject { ["author_login"] = "dependabot[bot]", ["verified"] = true },
514new JsonObject { ["author_login"] = "someone", ["verified"] = true });
518scenario["commits"] = new JsonArray(new JsonObject { ["author_login"] = "dependabot[bot]", ["verified"] = false });
555scenario["responses"]!["https://registry.npmjs.org/react"] = Response(new JsonObject { ["time"] = new JsonObject { ["18.2.0"] = "2026-09-01T00:00:00Z" } });
563scenario["responses"]!["https://registry.npmjs.org/foo"] = Response(new JsonObject { ["time"] = new JsonObject { ["2.1.0"] = "2026-09-01T00:00:00Z" } });
571scenario["responses"]!["https://registry.npmjs.org/foo"] = Response(new JsonObject { ["time"] = new JsonObject { ["2.1.0"] = "2026-09-01T00:00:00Z" } });
579scenario["responses"]!["https://registry.npmjs.org/minimist"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.2.8"] = "2026-09-01T00:00:00Z" } });
580scenario["alerts"]!.AsArray().Add(new JsonObject
595scenario["responses"]!["https://registry.npmjs.org/minimist"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.2.8"] = "2026-09-28T00:00:00Z" } });
646scenario["liveCheckRuns"] = new JsonArray(new JsonObject { ["name"] = "tests", ["status"] = "in_progress", ["conclusion"] = null });
651scenario["liveStatuses"] = new JsonArray(new JsonObject { ["context"] = "license/cla", ["state"] = "failure" });
667scenario["responses"]!["https://registry.npmjs.org/minimist"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.2.8"] = "2026-09-01T00:00:00Z" } });
679scenario["checkRuns"]!.AsArray().Add(new JsonObject { ["name"] = "tests", ["status"] = "in_progress", ["conclusion"] = null });
682scenario["statuses"] = new JsonArray(new JsonObject { ["context"] = "license/cla", ["state"] = "pending" });
690statuses.Add(new JsonObject { ["context"] = $"ok-{i}", ["state"] = "success" });
692statuses.Add(new JsonObject { ["context"] = "license/cla", ["state"] = "failure" });
697scenario["statuses"] = new JsonArray(new JsonObject { ["context"] = "license/cla", ["state"] = "success" });
701scenario["reviews"] = new JsonArray(new JsonObject { ["user_login"] = "aspire-repo-bot[bot]", ["state"] = "APPROVED", ["commit_id"] = HeadSha });
719var result = await RunHarnessAsync(new JsonObject
723["args"] = new JsonArray(new JsonObject
726new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 5, ["head_sha"] = HeadSha },
727new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 5, ["head_sha"] = HeadSha },
728new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 6, ["head_sha"] = "main" },
729new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = -1, ["head_sha"] = HeadSha },
730new JsonObject { ["type"] = "create_pull_request", ["pr_number"] = 7, ["head_sha"] = HeadSha }),
752var result = await RunHarnessAsync(new JsonObject
773var result = await RunHarnessAsync(new JsonObject
830var result = await RunHarnessAsync(new JsonObject
887var workspaceFiles = new JsonObject
891var request = new JsonObject
894["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
897["responses"] = new JsonObject
899["https://registry.npmjs.org/lodash"] = Response(new JsonObject
901["time"] = new JsonObject { ["4.17.21"] = "2026-08-01T00:00:00Z", ["4.17.22"] = "2026-08-30T00:00:00Z", ["5.0.0"] = "2026-08-01T00:00:00Z" },
903["https://api.nuget.org/v3/registration5-gz-semver2/x/9.0.5.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
904["https://api.nuget.org/v3/registration5-gz-semver2/x/9.0.6.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
906[$"{flat}x/index.json"] = Response(new JsonObject { ["versions"] = new JsonArray("9.0.4", "9.0.5") }),
915request["branchFiles"] = new JsonObject { [path] = baseText };
921request["branchFiles"] = new JsonObject { [path] = baseText + "{\"resolved\": \"https://evil.example/lodash/-/lodash-4.17.21.tgz\"}\n" };
975var result = await RunHarnessAsync(new JsonObject
978["patchFiles"] = new JsonObject
983["workspaceFiles"] = new JsonObject
989["responses"] = new JsonObject
991["https://registry.npmjs.org/lodash"] = Response(new JsonObject
993["time"] = new JsonObject { ["4.17.21"] = "2026-08-01T00:00:00Z", ["4.17.22"] = "2026-08-30T00:00:00Z", ["5.0.0"] = "2026-08-01T00:00:00Z" },
995["https://api.nuget.org/v3/registration5-gz-semver2/x/9.0.5.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
996["https://api.nuget.org/v3/registration5-gz-semver2/x/9.0.6.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
998[$"{flat}x/index.json"] = Response(new JsonObject { ["versions"] = new JsonArray("9.0.4", "9.0.5") }),
1011var result = await RunHarnessAsync(new JsonObject
1014["patchFiles"] = new JsonObject
1043var request = new JsonObject
1046["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
1050request["workspaceFiles"] = new JsonObject { ["extension/package-lock.json"] = baseText };
1127var result = await RunHarnessAsync(new JsonObject
1131["workspaceFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase },
1133["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch },
1154var result = await RunHarnessAsync(new JsonObject
1171var result = await RunHarnessAsync(new JsonObject
1175["workspaceFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase },
1177["patchFiles"] = new JsonObject
1195var result = await RunHarnessAsync(new JsonObject
1200["patchFiles"] = new JsonObject
1204["baseFiles"] = new JsonObject { [alias] = PublicTextBase },
1288? new JsonObject { ["type"] = "push_to_pull_request_branch", ["pull_request_number"] = 202, ["message"] = pushMessage }
1289: new JsonObject { ["type"] = "create_pull_request", ["branch"] = "auto-sec/security-updates", ["title"] = title, ["body"] = body };
1290var result = await RunHarnessAsync(new JsonObject
1294["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
1335var result = await RunHarnessAsync(new JsonObject
1349var result = await RunHarnessAsync(new JsonObject
1354new JsonArray(new JsonObject { ["malware"] = true }, new JsonObject()),
1355new JsonObject
1357["version_alerts"] = new JsonArray(new JsonObject()),
1358["other_rule_counts"] = new JsonArray(new JsonObject { ["count"] = 2 }, new JsonObject { ["count"] = 3 }),
1378var output = new JsonObject { ["type"] = "noop", ["message"] = message }.ToJsonString();
1379var result = await RunHarnessAsync(new JsonObject
1382["collectedCounts"] = new JsonObject { ["alerts"] = alerts, ["codeFindings"] = codeFindings },
1385["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.ReplaceLineEndings("\n") },
1387["workFiles"] = new JsonObject
1410var result = await RunHarnessAsync(new JsonObject
1423["outputLines"] = new JsonArray(new JsonObject
1443var output = new JsonObject
1448var result = await RunHarnessAsync(new JsonObject
1475var result = await RunHarnessAsync(new JsonObject
1480["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1499var result = await RunHarnessAsync(new JsonObject
1503["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1538var result = await RunHarnessAsync(new JsonObject
1542["baseFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase },
1543["generatedPatch"] = new JsonObject
1545["headFiles"] = new JsonObject
1601var result = await RunHarnessAsync(new JsonObject
1605["baseFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase },
1606["generatedPatch"] = new JsonObject
1609new JsonObject { ["headFiles"] = new JsonObject { ["extension/package-lock.json"] = firstHead }, ["message"] = firstMessage },
1610new JsonObject
1612["headFiles"] = new JsonObject { ["extension/package-lock.json"] = firstHead.Replace("4.17.20", "4.17.21", StringComparison.Ordinal).Replace("22.0.1", "22.1.0", StringComparison.Ordinal) },
1658? new JsonObject
1662: new JsonObject
1669var heads = new JsonObject();
1679head["packages"]!["node_modules/y"] = new JsonObject { ["version"] = "1.0.2" };
1687var result = await RunHarnessAsync(new JsonObject
1692["generatedPatch"] = new JsonObject { ["headFiles"] = heads, ["message"] = field == "commit" ? message : complete },
1729var result = await RunHarnessAsync(new JsonObject
1734["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1735["workFiles"] = new JsonObject { [filename] = "private advisory detail" },
1748var result = await RunHarnessAsync(new JsonObject
1753["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1754["workFiles"] = new JsonObject { ["safeoutputs/private.txt"] = "private advisory detail" },
1767var result = await RunHarnessAsync(new JsonObject
1771["collectedCounts"] = new JsonObject { ["alerts"] = 2, ["codeFindings"] = 5 },
1773new JsonObject { ["type"] = "create_pull_request", ["branch"] = "auto-sec/security-updates", ["title"] = "Automated dependency updates", ["body"] = PublicTextBody.Replace("\r\n", "\n") }.ToJsonString(),
1774new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 101, ["head_sha"] = headSha, ["note"] = "fixes alert 42" }.ToJsonString(),
1775new JsonObject { ["type"] = "report_missing_tool", ["tool"] = "alerts", ["reason"] = "alert 42 needs a tool" }.ToJsonString(),
1776new JsonObject { ["type"] = "noop", ["message"] = "alerts=2 dependabot-pr=1 auto-sec-pr=1 blocked=0 code-findings-out-of-scope=5" }.ToJsonString()),
1777["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1778["workFiles"] = new JsonObject
1799item => Assert.Equal(new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 101, ["head_sha"] = headSha }.ToJsonString(), item.ToJsonString()),
1810var result = await RunHarnessAsync(new JsonObject
1815["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
1845var result = await RunHarnessAsync(new JsonObject
1850["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
1893baseline["metadata"] = new JsonArray(new JsonObject { ["version"] = "1.0.0" });
1914head["node_modules/alert-42"] = new JsonObject { ["version"] = "1.2.3" };
1917head["dependencies"] = new JsonObject { ["alert-42"] = "1.2.3" };
1920head["requires"] = new JsonObject { ["alert-42"] = "1.2.3" };
1923package["engines"] = new JsonObject { ["alert-42"] = "1.2.3" };
1936package[scenario] = new JsonObject { ["@types/node"] = "^22.1.0" };
1950var result = await RunHarnessAsync(new JsonObject
1954["baseFiles"] = new JsonObject { [path] = baseText },
1955["generatedPatch"] = new JsonObject
1957["headFiles"] = new JsonObject { [path] = text },
1996var baseline = new JsonObject { ["lockfileVersion"] = version, ["requires"] = true };
1999baseline["dependencies"] = new JsonObject
2001["lodash"] = new JsonObject
2004["requires"] = new JsonObject { ["@types/node"] = "^22.0.0" },
2005["dependencies"] = new JsonObject { ["@types/node"] = new JsonObject { ["version"] = "22.0.0" } },
2007["@types/node"] = new JsonObject { ["version"] = "22.0.0" },
2017var result = await RunHarnessAsync(new JsonObject
2021["baseFiles"] = new JsonObject { [path] = baseText },
2022["generatedPatch"] = new JsonObject
2024["headFiles"] = new JsonObject { [path] = baseText.Replace("4.17.20", "4.17.21", StringComparison.Ordinal).Replace("22.0.0", "22.1.0", StringComparison.Ordinal) },
2057baseline["dependencies"] = new JsonObject
2072baseline["dependencies"]!["parent"] = new JsonObject
2075["dependencies"] = new JsonObject { ["lodash"] = new JsonObject { ["version"] = "4.17.20" } },
2080baseline["packages"]!["node_modules/parent/node_modules/lodash"] = new JsonObject { ["version"] = "4.17.20" };
2111var result = await RunHarnessAsync(new JsonObject
2115["baseFiles"] = new JsonObject { [path] = baseline.ToJsonString(options) + "\n" },
2116["generatedPatch"] = new JsonObject
2118["headFiles"] = new JsonObject { [path] = head.ToJsonString(options) + "\n" },
2202var result = await RunHarnessAsync(new JsonObject
2206["baseFiles"] = new JsonObject { [path] = baseText },
2207["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = headText }, ["message"] = message },
2243var result = await RunHarnessAsync(new JsonObject
2246["workspaceFiles"] = new JsonObject { ["extension/package.json"] = PackageJsonBase, ["extension/package-lock.json"] = baseText },
2247["patchFiles"] = new JsonObject
2272baseline["packages"]![""] = new JsonObject { ["dependencies"] = new JsonObject { ["lodash"] = "^4.17.20" } };
2277baseline["packages"]!["node_modules/existing/node_modules/lodash"] = new JsonObject
2297head["packages"]!["node_modules/new/node_modules/lodash"] = new JsonObject
2307var result = await RunHarnessAsync(new JsonObject
2311["baseFiles"] = new JsonObject { [path] = baseline.ToJsonString(options) + "\n" },
2312["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = head.ToJsonString(options) + "\n" }, ["message"] = message },
2361var result = await RunHarnessAsync(new JsonObject
2365["baseFiles"] = new JsonObject { [path] = baseText },
2366["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = headText }, ["message"] = message },
2430var result = await RunHarnessAsync(new JsonObject
2434["baseFiles"] = new JsonObject { [path] = baseText },
2435["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = headText }, ["message"] = message },
2473var result = await RunHarnessAsync(new JsonObject
2477["baseFiles"] = new JsonObject { [path] = baseText },
2478["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = headText }, ["message"] = message },
2512var result = await RunHarnessAsync(new JsonObject
2516["baseFiles"] = new JsonObject { [path] = baseText },
2517["generatedPatch"] = new JsonObject { ["headFiles"] = new JsonObject { [path] = headText }, ["message"] = message },
2542var result = await RunHarnessAsync(new JsonObject
2547["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2578var result = await RunHarnessAsync(new JsonObject
2583["baseFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase, ["extension/package.json"] = baseText },
2584["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2633var result = await RunHarnessAsync(new JsonObject
2638["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2661var result = await RunHarnessAsync(new JsonObject
2666["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2681var result = await RunHarnessAsync(new JsonObject
2686["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
2687["workFiles"] = new JsonObject { [name] = patch ? PublicTextPatch.Replace("\r\n", "\n") : "alert 42: prototype pollution" },
2729var result = await RunHarnessAsync(new JsonObject
2735["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2761var result = await RunHarnessAsync(new JsonObject
2766["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2806var result = await RunHarnessAsync(new JsonObject
2846var result = await RunHarnessAsync(new JsonObject
2866var result = await RunHarnessAsync(new JsonObject
2870["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
2872["baseFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase, [path] = baseText },
2901var result = await RunHarnessAsync(new JsonObject
2905["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
2922var result = await RunHarnessAsync(new JsonObject
2928["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
2948var result = await RunHarnessAsync(new JsonObject
2952["generatedPatch"] = new JsonObject
2954["headFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase.Replace("4.17.20", "4.17.21", StringComparison.Ordinal).Replace("22.0.0", "22.1.0", StringComparison.Ordinal) },
2978var result = await RunHarnessAsync(new JsonObject
2983["branchFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase },
2986["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
3006var result = await RunHarnessAsync(new JsonObject
3012["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
3030var request = new JsonObject
3035["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
3037request[source == "workspace" ? "workspaceFiles" : "branchFiles"] = new JsonObject { ["extension/package-lock.json"] = PublicTextBase };
3059? new JsonObject { ["private advisory"] = new JsonArray("alert 42") }
3061var result = await RunHarnessAsync(new JsonObject
3066["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
3093var result = await RunHarnessAsync(new JsonObject
3097["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
3130var result = await RunHarnessAsync(new JsonObject
3135["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
3148"create_pull_request" => new JsonObject { ["type"] = type, ["branch"] = "auto-sec/security-updates", ["title"] = "Automated dependency updates", ["body"] = PublicTextBody.Replace("\r\n", "\n") },
3149"push_to_pull_request_branch" => new JsonObject { ["type"] = type, ["pull_request_number"] = 202, ["message"] = "Update dependencies\n\nlodash 4.17.20 -> 4.17.21\n@types/node 22.0.0 -> 22.1.0" },
3150"approve_dependabot_pr" => new JsonObject { ["type"] = type, ["pr_number"] = 101, ["head_sha"] = "0123456789abcdef0123456789abcdef01234567" },
3151"noop" => new JsonObject { ["type"] = type, ["message"] = "alerts=1 dependabot-pr=0 auto-sec-pr=1 blocked=0 code-findings-out-of-scope=0" },
3169var second = new JsonObject { ["type"] = "noop", ["message"] = "alerts=1 dependabot-pr=0 auto-sec-pr=1 blocked=0 code-findings-out-of-scope=0" }.ToJsonString();
3173second = new JsonObject { ["type"] = "noop", ["message"] = "Fixed alert 42 in lodash" }.ToJsonString();
3179second = new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 101, ["head_sha"] = "alert 42" }.ToJsonString();
3195var result = await RunHarnessAsync(new JsonObject
3199new JsonObject { ["type"] = "create_pull_request", ["branch"] = "auto-sec/security-updates", ["title"] = "Automated dependency updates", ["body"] = body }.ToJsonString(),
3201["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = patch },
3232var result = await RunHarnessAsync(new JsonObject
3235["ioFailure"] = new JsonObject { ["operation"] = operation, ["path"] = path },
3237["outputLines"] = new JsonArray(new JsonObject
3242["patchFiles"] = new JsonObject { ["aw-auto-sec-security-updates.patch"] = PublicTextPatch.Replace("\r\n", "\n") },
3243["workFiles"] = new JsonObject
3269var result = await RunHarnessAsync(new JsonObject
3274["stepOutputs"] = ready is null ? new JsonObject() : new JsonObject { ["publication_ready"] = ready },
3286var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3303var result = await RunHarnessAsync(new JsonObject
3320var unguarded = await RunHarnessAsync(new JsonObject { ["mode"] = "private-shell", ["script"] = script });
3328var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3332var quiet = await RunHarnessAsync(new JsonObject
3348var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = PublicationGuardFixture });
3369var original = await RunHarnessAsync(new JsonObject { ["mode"] = "private-shell", ["script"] = script });
3376var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3379var quiet = await RunHarnessAsync(new JsonObject
3402var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3430var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3446var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3473var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3543var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3564var result = await RunHarnessAsync(new JsonObject { ["mode"] = "publication-guard", ["workflow"] = workflow });
3783var result = await RunHarnessAsync(new JsonObject
3806var result = await RunHarnessAsync(new JsonObject
3825var result = await RunHarnessAsync(new JsonObject
3828["patchFiles"] = new JsonObject { ["aw-test.patch"] = ReplacementPatch("uv.lock", baseText, source, $"source = {{ {kind} = \"../pkg\" }}") },
3829["workspaceFiles"] = new JsonObject { ["uv.lock"] = baseText },
3850var result = await RunHarnessAsync(new JsonObject
3887var result = await RunHarnessAsync(new JsonObject
3930var result = await RunHarnessAsync(new JsonObject
3947scenario["responses"]!["https://registry.npmjs.org/minimist"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.2.8"] = "2026-09-01T00:00:00Z" } });
3948scenario["responses"]!["https://registry.npmjs.org/left-pad"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.3.0"] = "2026-09-01T00:00:00Z" } });
3963scenario["alerts"]!.AsArray().Add(new JsonObject
3987scenario["responses"]!["https://registry.npmjs.org/minimist"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.2.8"] = "2026-09-01T00:00:00Z" } });
3988scenario["alerts"]!.AsArray().Add(new JsonObject
4034scenario["alerts"]!.AsArray().Add(new JsonObject
4056var overrides = new JsonObject();
4059items.Add(new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = number, ["head_sha"] = HeadSha });
4062overrides[number.ToString(System.Globalization.CultureInfo.InvariantCulture)] = new JsonObject { ["user_login"] = "someone" };
4087items.Add(new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = number, ["head_sha"] = HeadSha });
4126var result = await RunHarnessAsync(new JsonObject
4140var result = await RunHarnessAsync(new JsonObject
4187var result = await RunHarnessAsync(new JsonObject
4202new JsonObject { ["number"] = 1, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = "4.17.21", ["malware"] = false },
4203new JsonObject { ["number"] = 2, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "other/yarn.lock", ["first_patched_version"] = "4.17.21", ["malware"] = false },
4204new JsonObject { ["number"] = 3, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = "4.17.22", ["malware"] = false },
4205new JsonObject { ["number"] = 4, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = null, ["malware"] = true, ["vulnerable_ranges"] = new JsonArray(">= 4.17.20, < 4.17.21") },
4208new JsonObject { ["number"] = 12, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = null, ["malware"] = true, ["vulnerable_ranges"] = new JsonArray(">= 0") },
4209new JsonObject { ["number"] = 13, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = null, ["malware"] = true },
4210new JsonObject { ["number"] = 5, ["ecosystem"] = "pip", ["package"] = "lodash", ["manifest_path"] = "app/uv.lock", ["first_patched_version"] = "4.17.21", ["malware"] = false },
4211new JsonObject { ["number"] = 6, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "nested/yarn.lock", ["first_patched_version"] = "4.17.21", ["malware"] = false },
4212new JsonObject { ["number"] = 8, ["ecosystem"] = "npm", ["package"] = "lodash", ["manifest_path"] = "nested/yarn.lock", ["first_patched_version"] = null, ["malware"] = true },
4214new JsonObject { ["number"] = 9, ["ecosystem"] = "npm", ["package"] = "minimist", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = "1.2.6", ["malware"] = false },
4216new JsonObject { ["number"] = 10, ["ecosystem"] = "npm", ["package"] = "left-pad", ["manifest_path"] = "app/yarn.lock", ["first_patched_version"] = "1.3.1", ["malware"] = false },
4218new JsonObject { ["number"] = 11, ["ecosystem"] = "npm", ["package"] = "left-pad", ["manifest_path"] = "other/yarn.lock", ["first_patched_version"] = "1.3.1", ["malware"] = false });
4219var updates = new JsonArray(new JsonObject { ["name"] = "lodash", ["from"] = "4.17.20", ["to"] = "4.17.21" });
4220var versionChanges = new JsonArray(new JsonObject { ["name"] = "minimist", ["from"] = new JsonArray("1.2.5"), ["to"] = "1.2.8" });
4221var headContents = new JsonObject
4228var baseContents = new JsonObject
4235var result = await RunHarnessAsync(new JsonObject
4254new JsonObject { ["number"] = 1, ["ecosystem"] = "npm", ["package"] = "left-pad", ["manifest_path"] = "app/package-lock.json", ["first_patched_version"] = "1.3.1", ["malware"] = false });
4255var baseContents = new JsonObject
4260var result = await RunHarnessAsync(new JsonObject
4264["args"] = new JsonArray(alerts, "npm", new JsonArray(), new JsonArray(), new JsonObject { ["app/package-lock.json"] = headText }, baseContents),
4274var result = await RunHarnessAsync(new JsonObject
4282["responses"] = new JsonObject
4284["https://api.nuget.org/v3/registration5-gz-semver2/system.text.json/9.0.5.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
4286["https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-eng/nuget/v3/flat2/system.text.json/index.json"] = Response(new JsonObject { ["versions"] = new JsonArray("9.0.4", "9.0.5") }),
4316var responses = new JsonObject
4318["https://api.nuget.org/v3/registration5-gz-semver2/contoso.build.engine/1.0.0.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
4320[$"{transportFlat}contoso.build.engine/index.json"] = Response(new JsonObject { ["versions"] = new JsonArray("1.0.0") }),
4342static JsonObject NuGetLookup(string name, string config, JsonObject responses) => new()
4361var leaf = new JsonObject { ["published"] = published };
4366var result = await RunHarnessAsync(new JsonObject
4373["responses"] = new JsonObject { ["https://api.nuget.org/v3/registration5-gz-semver2/contoso.lib/1.2.3.json"] = Response(leaf) },
4383var nuget = await RunHarnessAsync(new JsonObject
4391["responses"] = new JsonObject
4393["https://api.nuget.org/v3/registration5-gz-semver2/contoso.lib/1.2.3.json"] = Response(new JsonObject { ["published"] = "2026-08-01T00:00:00Z" }),
4396var npm = await RunHarnessAsync(new JsonObject
4403["responses"] = new JsonObject
4405["https://registry.npmjs.org/@scope%2Fpkg"] = Response(new JsonObject { ["time"] = new JsonObject { ["1.0.1"] = "2026-09-29T00:00:00Z" } }),
4406["https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-public-npm/npm/registry/@scope%2Fpkg"] = Response(new JsonObject { ["versions"] = new JsonObject { ["1.0.1"] = new JsonObject() } }),
4420var pip = await RunHarnessAsync(new JsonObject
4427["responses"] = new JsonObject
4429["https://pypi.org/pypi/requests/2.32.3/json"] = Response(new JsonObject
4432new JsonObject { ["upload_time_iso_8601"] = "2026-09-29T00:00:00Z" },
4433new JsonObject { ["upload_time_iso_8601"] = "2026-08-01T00:00:00Z" }),
4446var result = await RunHarnessAsync(CreatePushGateScenario(new JsonObject()));
4451var noPush = await RunHarnessAsync(new JsonObject
4454["agentItems"] = new JsonArray(new JsonObject { ["type"] = "create_pull_request" }),
4484var closed = new JsonObject
4487["user"] = new JsonObject { ["login"] = "aspire-repo-bot[bot]" },
4488["head"] = new JsonObject
4492["repo"] = new JsonObject { ["full_name"] = "microsoft/aspire" },
4494["base"] = new JsonObject { ["ref"] = "main" },
4496["labels"] = new JsonArray(new JsonObject { ["name"] = "auto-sec" }),
4498var scenario = new JsonObject
4501["agentItems"] = new JsonArray(new JsonObject { ["type"] = "create_pull_request", ["branch"] = "auto-sec/security-updates" }),
4502["branch"] = new JsonObject { ["commit"] = new JsonObject { ["sha"] = HeadSha } },
4508case "open-pr": scenario["openPrs"] = new JsonArray(new JsonObject { ["state"] = "open", ["user"] = new JsonObject { ["login"] = "someone" } }); break;
4555var pr = new JsonObject();
4556var item = new JsonObject { ["type"] = "push_to_pull_request_branch", ["pull_request_number"] = 202 };
4594var scenario = CreatePushGateScenario(new JsonObject { ["user_login"] = author });
4693var pr = new JsonObject
4707return new JsonObject
4711["agentItems"] = new JsonArray(item ?? new JsonObject { ["type"] = "push_to_pull_request_branch", ["pull_request_number"] = 202 }),
4715private static JsonObject Response(JsonNode body) => new() { ["status"] = 200, ["body"] = body };
4728private static JsonObject ServiceIndex(string flatContainer) => Response(new JsonObject
4730["resources"] = new JsonArray(new JsonObject { ["@id"] = flatContainer, ["@type"] = "PackageBaseAddress/3.0.0" }),
4733private static JsonObject CreateCollectionScenario() => new()
4736["prs"] = new JsonArray(new JsonObject
4745["statusCheckRollup"] = new JsonArray(new JsonObject { ["conclusion"] = "SUCCESS" }),
4748new JsonArray(new JsonObject { ["filename"] = "README.md", ["status"] = "modified" }),
4749new JsonArray(new JsonObject { ["filename"] = "extension/yarn.lock", ["status"] = "modified" })),
4750["contents"] = new JsonObject
4755["alerts"] = new JsonArray(new JsonObject
4778var result = await RunHarnessAsync(new JsonObject
4798private static JsonObject CreateApprovalScenario() => new()
4803["agentItems"] = new JsonArray(new JsonObject { ["type"] = "approve_dependabot_pr", ["pr_number"] = 101, ["head_sha"] = HeadSha }),
4804["pr"] = new JsonObject
4814["contents"] = new JsonObject
4821["alerts"] = new JsonArray(new JsonObject
4830["checkRuns"] = new JsonArray(new JsonObject { ["name"] = "ci", ["status"] = "completed", ["conclusion"] = "success" }),
4833["responses"] = new JsonObject
4835["https://registry.npmjs.org/lodash"] = Response(new JsonObject { ["time"] = new JsonObject { ["4.17.21"] = "2026-09-01T00:00:00Z" } }),
4843request["baseFiles"] ??= new JsonObject
Microsoft.AspNetCore.OpenApi (23)
Microsoft.Extensions.AI (4)
Microsoft.Extensions.AI.Abstractions (9)
Microsoft.Extensions.AI.Abstractions.Tests (2)
Microsoft.Extensions.AI.Evaluation.Quality (1)
Microsoft.Extensions.AI.Evaluation.Safety (13)
Microsoft.NET.Build.Containers (9)
Microsoft.NET.Build.Tasks (4)
Microsoft.NETCore.Platforms (1)
Microsoft.TemplateEngine.Cli (3)
Microsoft.TemplateEngine.Orchestrator.RunnableProjects (1)
MSBuild (8)
NativeIntegrations.DockerCompose (55)
ComposeModels.cs (15)
25var result = new JsonObject();
32result["build"] = new JsonObject { ["context"] = Build.Context, ["dockerfile"] = Build.Dockerfile };
42var exposure = new JsonObject { ["endpoint"] = port.Endpoint, ["hostIp"] = port.HostIp };
145(Model["volumes"] ??= new JsonArray()).AsArray().Add(new JsonObject
192var service = new JsonObject { ["image"] = ComposeJson.Literal(image), ["labels"] = new JsonObject() };
195service["environment"] = new JsonObject(environment.Select(pair =>
206var volume = new JsonObject();
213volume["labels"] = new JsonObject(labels.Select(pair =>
218public void AddConfig(string name, string content) => Add("configs", name, new() { ["content"] = ComposeJson.Literal(content) });
221var secret = new JsonObject { ["external"] = true };
231(Model[collection] ??= new JsonObject()).AsObject()[name] = value;
314return new() { ["context"] = Literal(context), ["dockerfile"] = Literal(dockerfile) };
323var result = new JsonObject { ["test"] = Strings(value.Test.Select(part => escape ? Literal(Text(part, true)) : Text(part, true))) };
351JsonObject obj => new JsonObject(obj.Select(pair => KeyValuePair.Create(pair.Key, EscapeNode(pair.Value)))),
DockerComposeGenerator.cs (34)
102var inputs = new JsonObject
104["schemaVersion"] = 1, ["projectName"] = project, ["parameters"] = new JsonArray(), ["variables"] = new JsonObject()
108var compose = new JsonObject { ["name"] = project, ["services"] = new JsonObject() };
132var service = new JsonObject
134["image"] = ComposeJson.Literal(image ?? ""), ["labels"] = new JsonObject { ["aspire.resource"] = ComposeJson.Literal(resourceName) }
181service["environment"] = new JsonObject(serviceEnvironment);
192var exposure = new JsonObject { ["endpoint"] = Text(endpoint, "name") };
211var value = new JsonObject { ["target"] = exposure.Target };
234var captured = (inputs["environment"] ??= new JsonObject()).AsObject();
239captured[variable] = new JsonObject
254volumes[key] = new JsonObject();
262return (JsonNode)new JsonObject
271service["depends_on"] = new JsonObject(dependencies.Select(dependency =>
272KeyValuePair.Create(names[dependency], (JsonNode?)new JsonObject
286compose["volumes"] = new JsonObject(volumes);
288inputs["parameters"] = new JsonArray(used.Select(parameter => (JsonNode)new JsonObject
316return new() { ["kind"] = "literal", ["value"] = ComposeJson.Text(Text(value, "value"), true) };
325return new() { ["kind"] = "parameter", ["name"] = parameter };
329return new() { ["kind"] = "endpoint", ["resource"] = Text(value, "resource"), ["endpoint"] = Text(value, "endpoint"), ["property"] = Text(value, "property") };
331return new() { ["kind"] = "composite", ["parts"] = new JsonArray(Objects(value["parts"]).Select(part => (JsonNode)Normalize(part, depth + 1)).ToArray()) };
333return new() { ["kind"] = "uriEncoded", ["value"] = Normalize(value["value"]!.AsObject(), depth + 1) };
408var captured = (plan.Inputs["environment"] ??= new JsonObject()).AsObject();
414var entry = new JsonObject { ["description"] = $"Deployment parameter {name}", ["secret"] = secret };
426var configuration = source is null ? new JsonObject
451plan.Compose["networks"] = new JsonObject { ["default"] = new JsonObject
472var variables = new JsonObject
482var dashboard = new JsonObject
485["labels"] = new JsonObject { ["aspire.resource"] = resourceName }, ["environment"] = variables,
490dashboard["ports"] = new JsonArray(new JsonObject
501var captured = (plan.Inputs["environment"] ??= new JsonObject()).AsObject();
506captured[variable] = new JsonObject { ["description"] = description, ["secret"] = true };
514var options = resource["configuration"]?["publish.dockerCompose"] is { } source ? JsonNode.Parse(source.GetValue<string>())!.AsObject() : new JsonObject();
NuGet.Protocol (10)
SelectTests (5)
ServiceBus.AppHost (1)
Shared.Tests (1)
Stress.ApiService (1)
System.Text.Json (10)
TestProject.AppHost (3)
2523 references to JsonObject
AnalyzeCiFailure (98)
AnalysisPublisher.cs (34)
100File.Exists(storedRunPath) ? Read(storedRunPath) as JsonObject : null);
104var record = (JsonObject)Read(runPath)!;
132var occurrence = CreateOccurrence(analysis, cause, runId, _observedAt);
133JsonObject? existing = null;
137existing = Read(path) as JsonObject ?? throw new ValidationException($"Stored cause is not readable: {cause.FileName}");
160var definition = existing ?? (JsonObject?)ToNode(cause.Definition)
162var history = MergeCause(definition, existing, occurrence);
169private async Task<Dictionary<string, JsonObject?>> ResolveDestinationsAsync(List<PreparedCause> prepared)
172var destinations = new Dictionary<string, JsonObject?>(StringComparer.Ordinal);
175JsonObject? issue = null;
180issue = await _github.GetAsync($"repos/{_repository}/issues/{linked.Split('/')[^1]}") as JsonObject;
189issue = issueInventory.OfType<JsonObject>().Where(i => MatchesIssue(i, cause))
196issue = await _github.GetAsync($"repos/{_repository}/issues/{number}") as JsonObject;
230var storedRun = File.Exists(runPath) ? Read(runPath) as JsonObject : null;
231var record = (JsonObject)ToNode(RunSummaryBuilder.Create(analysis.Report, analysis.Evidence, evidence, _observedAt))!;
249Dictionary<string, JsonObject?> destinations)
253var issue = destinations[cause.Id];
277var request = new JsonObject();
349JsonObject history,
350JsonObject? issue,
414internal static JsonObject MergeCause(JsonObject definition, JsonObject? existing, JsonObject occurrence)
416var history = (JsonObject)(existing ?? definition).DeepClone();
430internal static JsonObject CreateOccurrence(ValidatedAnalysis analysis, FailureCause cause, JsonNode runId, string observedAt)
471return (JsonObject)ToNode(occurrence)!;
474private static bool MatchesIssue(JsonObject issue, FailureCause cause)
634private sealed record PreparedCause(FailureCause Cause, JsonObject History, string Path, bool Replayed);
BranchHistoryReader.cs (15)
18public async Task<JsonObject> FindLastSuccessfulRunAsync(string workflowId, string failedTime, long failedId)
33var found = await FindLastSuccessfulRunInWindowAsync(start, end, workflowId, failedTime, failedId);
45private async Task<JsonObject> FindLastSuccessfulRunInWindowAsync(long start, long end, string workflowId, string failedTime, long failedId)
53static bool HasValidWorkflowRunRows(JsonNode? page) => page is JsonObject && Field(page, "workflow_runs") is JsonArray rows &&
54rows.All(run => run is JsonObject && GitHubJson.TryReadId(Field(run, "id"), out _) &&
76var newer = await FindLastSuccessfulRunInWindowAsync(midpoint, end, workflowId, failedTime, failedId);
106return newest is JsonObject result ? (JsonObject)result.DeepClone() : [];
128array.Any(p => p is not JsonObject || Field(p, "commits") is not JsonArray) ||
130c is not JsonObject || Text(c["sha"]) is not { Length: > 0 } ||
131c["commit"] is not JsonObject || Text(Field(c["commit"], "message")) is null || Text(c["html_url"]) is null))
146JsonObject[] prs;
163var pr = prs[0];
182public JsonObject[] FindMergedPullRequests(JsonArray candidates)
183=> candidates.OfType<JsonObject>().Where(pr => Text(Field(Field(pr["base"], "repo"), "full_name")) == repository &&
AnalyzeCiFailure.TestHost (4)
AnalyzeCiFailure.Tests (53)
AnalyzeCiFailurePublicationTests.cs (12)
205var issue = new JsonObject
223JsonObject? history = storedLink
391var history = storedLink ? JsonNode.Parse("""
612var history = new JsonObject
879JsonObject? history = null,
1065private static JsonObject CreateTrustedOccurrence(string scope, string prNumbers, string job)
1336var definition = JsonNode.Parse("""{"id":"timeout","type":"flaky-test","title":"New title"}""")!.AsObject();
1337var existing = JsonNode.Parse(
1339var occurrence = JsonNode.Parse(
1342var merged = AnalyzeCiFailure.AnalysisPublisher.MergeCause(definition, existing, occurrence);
1368var occurrence = AnalyzeCiFailure.AnalysisPublisher.CreateOccurrence(collected, Assert.Single(collected.Causes), JsonValue.Create(value: 123)!, "2026-10-21T01:00:00Z");
1377var projection = new JsonObject
aspire (321)
Agents\AspireSkills\AspireSkillsRemoteConfiguration.cs (28)
31var plugins = pluginsNode.AsObject();
52public static void ApplyOpenCodeCatalog(JsonObject root, IEnumerable<JsonObject> configs, IReadOnlyList<SkillSource> skillSources)
66foreach (var config in settings)
93public static bool HasOpenCodeCatalog(JsonObject root, IReadOnlyList<SkillSource> sources)
98internal static JsonArray? ReadOpenCodeSkills(JsonObject root)
105if (skills is JsonObject v1)
144JsonObject root, IEnumerable<string> settingsPaths, string targetPath,
153foreach (var config in settings.Append(root))
169private static void ApplyPlugin(JsonObject root, IReadOnlyList<JsonObject> settings, SkillSource skillSource)
173JsonObject? selectedSource = null;
174foreach (var config in settings.Append(root))
176var plugins = OptionalObject(config, "enabledPlugins");
185var marketplaces = OptionalObject(config, "extraKnownMarketplaces");
189var source = OptionalObject(marketplaceNode.AsObject(), "source");
216var targetMarketplaces = Object(root, "extraKnownMarketplaces");
227var targetPlugins = Object(root, "enabledPlugins");
237public static async Task<IReadOnlyList<JsonObject>> ReadSettingsAsync(
240var settings = new List<JsonObject>();
253public static JsonObject? OptionalObject(JsonObject parent, string key)
264public static JsonObject Object(JsonObject parent, string key)
266var value = OptionalObject(parent, key);
276public static JsonArray? OptionalStrings(JsonObject parent, string key)
301public static bool? Boolean(JsonObject parent, string key)
315private static bool IsMatchingSource(JsonObject source, SkillSource configuration)
Agents\OpenCode\OpenCodeAgentClient.cs (13)
59public async Task<(JsonObject Config, string Path)> ReadMcpConfigAsync(
63var config = await McpConfigFileHelper.ReadConfigAsync(configFilePath, s_mcp.JsonDocumentOptions, edit, cancellationToken);
77var candidateConfig = StringComparers.FileSystemPath.Equals(candidate, configFilePath)
91server is not JsonObject aspire ||
106JsonObject config, string configFilePath, bool configureServer, AgentConfigurationScope scope)
109var root = native ? config["mcp"]!.AsObject() : config;
129private static (JsonObject? Servers, bool Native) GetMcpServerContainer(JsonObject root, string path)
131var mcp = McpConfigFileHelper.GetServerContainer(root, s_mcp.ServersPropertyName, path);
138var legacyServer = servers is JsonObject server &&
143if (servers is not JsonObject native)
185JsonObject config, DirectoryInfo workspaceRoot, AgentConfigurationScope scope,
197var inlineConfig = AgentConfiguration.ParseObject(inline);
Configuration\ConfigSourceService.cs (18)
297var configuration = await ReadProjectConfigurationAsync(path, cancellationToken);
324var configuration = await ReadProjectConfigurationAsync(path, cancellationToken);
353var configuration = await ReadConfigurationFileAsync(path, cancellationToken) ?? new JsonObject();
368internal async Task<JsonObject> GetTemplateSourcesAsync(CancellationToken cancellationToken)
401internal async Task<JsonObject> GetTemplateSourcesAsync(ConfigSource source, CancellationToken cancellationToken)
410var sources = new JsonObject();
417if (value is not JsonObject section)
451var configuration = await ReadConfigurationFileAsync(path, cancellationToken) ?? new JsonObject();
606private async Task<JsonObject?> ReadProjectConfigurationAsync(string configPath, CancellationToken cancellationToken)
613private static async Task<JsonObject?> ReadConfigurationFileAsync(string path, CancellationToken cancellationToken)
620var configuration = JsonNode.Parse(await File.ReadAllTextAsync(path, cancellationToken),
621documentOptions: ConfigurationHelper.ParseOptions) as JsonObject
630private static ConfigSource? ReadBinding(JsonObject? config)
839private async Task<(string Commit, string Version, JsonObject Configuration)> AcquireRepositoryAsync(
852var configuration = JsonNode.Parse(json, documentOptions: ConfigurationHelper.ParseOptions) as JsonObject
971var json = JsonSerializer.SerializeToNode(metadata, JsonSourceGenerationContext.Default.ConfigSourceCheckMetadata)!.AsObject();
1017private static string GetKey(JsonObject configuration, string key)
Configuration\ConfigurationService.cs (13)
38JsonObject settings;
92var settings = JsonNode.Parse(existingContent, nodeOptions: null, ConfigurationHelper.ParseOptions)?.AsObject();
215var settings = JsonNode.Parse(content, nodeOptions: null, ConfigurationHelper.ParseOptions)?.AsObject();
233private static void SetNestedValue(JsonObject settings, KeyPart[] keyParts, string key, string value)
258else if (child is not JsonObject and not JsonArray)
274private static void RemoveConflictingFlattenedKeys(JsonObject settings, string[] keyParts)
289if (settings.ContainsKey(partialKey) && settings[partialKey] is not JsonObject)
303if (current is not JsonObject and not JsonArray)
332if (child is JsonObject { Count: 0 } && current is JsonObject parent)
343private static void FlattenJsonObject(JsonObject obj, Dictionary<string, string> result, string prefix)
357if (value is JsonObject { Count: > 0 } obj)
509if (node is not JsonObject)
Scaffolding\PackageJsonMerger.cs (30)
58JsonObject? existingJson;
59JsonObject? scaffoldJson;
62existingJson = JsonNode.Parse(existingContent, documentOptions: s_jsonDocumentOptions) as JsonObject;
63scaffoldJson = JsonNode.Parse(scaffoldContent, documentOptions: s_jsonDocumentOptions) as JsonObject;
94private static void MergeObjects(JsonObject existing, JsonObject scaffold, ILogger logger, string toolchainCommand)
97var scaffoldScripts = scaffold[ScriptsKey]?.AsObject();
100var existingScripts = EnsureObject(existing, ScriptsKey, logger);
130else if (targetValue is JsonObject targetObj && sourceValue is JsonObject sourceObj)
151internal static void MergeScripts(JsonObject existingScripts, JsonObject scaffoldScripts, string toolchainCommand = "npm")
184private static void AddConvenienceAliases(JsonObject scripts, string toolchainCommand)
220private static void MergeDependencySection(JsonObject existing, JsonObject scaffold, string sectionName, ILogger logger)
222var scaffoldDeps = scaffold[sectionName]?.AsObject();
228var existingDeps = EnsureObject(existing, sectionName, logger);
262private static bool TryMergeExistingDependency(JsonObject existing, string sectionName, string packageName, string desiredVersion)
264if (existing[sectionName] is not JsonObject existingDeps)
291private static void MergeEngines(JsonObject existing, JsonObject scaffold, ILogger logger)
293var scaffoldEngines = scaffold[EnginesKey]?.AsObject();
299var existingEngines = EnsureObject(existing, EnginesKey, logger);
325internal static void DeepMerge(JsonObject target, JsonObject source)
340else if (targetValue is JsonObject targetObj && sourceValue is JsonObject sourceObj)
348private static JsonObject EnsureObject(JsonObject parent, string propertyName, ILogger logger)
350if (parent[propertyName] is JsonObject obj)
Scaffolding\ScaffoldingService.cs (12)
327JsonObject packageJson;
330packageJson = JsonNode.Parse(existingContent, documentOptions: s_scaffoldJsonDocumentOptions) as JsonObject
340var scripts = EnsureJsonObject(packageJson, "scripts");
355internal static IReadOnlyList<string> AddRootTypeScriptAppHostDelegateScripts(JsonObject scripts, TypeScriptAppHostToolchain toolchain, string relativeAppHostDirectory)
366internal static IReadOnlyList<string> AddRootTypeScriptAppHostDelegateScripts(JsonObject scripts, DirectoryInfo appHostDirectory, string relativeAppHostDirectory, IEnvironment environment, ILogger? logger)
372internal static string SerializePackageJson(JsonObject packageJson, string existingContent)
402private static JsonObject EnsureJsonObject(JsonObject parent, string propertyName)
404if (parent[propertyName] is JsonObject obj)
429private static void AddRootTypeScriptAppHostDelegateScript(JsonObject scripts, TypeScriptAppHostToolchain toolchain, string relativeAppHostDirectory, string scriptName, ref List<string>? preservedScriptNames)
726private static JsonObject? ParseJsonC(string content)
730return JsonNode.Parse(content, documentOptions: s_scaffoldJsonDocumentOptions) as JsonObject;
src\Shared\ConsoleLogs\SharedAIHelpers.cs (19)
150var dto = GetLogEntryDto(logEntry, promptContext, getResourceName, dashboardBaseUrl);
229public static JsonObject GetTraceSummaryDto(
280var summary = new JsonObject
322private static JsonObject GetSpanSummaryDto(OtlpSpanDto spanDto, Func<IOtlpResource, string> getResourceName)
336var spanObj = new JsonObject
393var dto = GetTraceDto(trace, promptContext, getResourceName, includeEvents: false, dashboardBaseUrl);
462public static JsonObject GetSpanDto(
475var attributesObj = new JsonObject();
510var eventAttributesObj = new JsonObject();
545var spanObj = new JsonObject
669public static JsonObject GetTraceDto(
681var spanObj = GetSpanDto(s, context, getResourceName, includeEvents, dashboardBaseUrl: null);
693var traceData = new JsonObject
805private static JsonObject StripNullProperties(JsonObject obj)
1077public static JsonObject GetLogEntryDto(
1089private static JsonObject GetLogEntryDto(
1114var attributesObject = new JsonObject();
1161var log = new JsonObject
Utils\ConfigurationHelper.cs (17)
241if (node is not JsonObject)
320internal static async Task WriteSettingsFileAsync(string filePath, JsonObject settings, CancellationToken cancellationToken = default)
329string filePath, JsonObject settings, CancellationToken cancellationToken,
713internal static void WriteSettingsFile(string filePath, JsonObject settings)
730private static JsonObject? AddSettingsFile(IConfigurationBuilder configuration, string filePath, bool persistNormalization)
747if (!persistNormalization && node is JsonObject settings)
759return node as JsonObject;
787var settings = JsonNode.Parse(content, documentOptions: ParseOptions)?.AsObject();
804internal static bool NormalizeSettings(JsonObject settings)
826var keyLookups = new Dictionary<JsonObject, Dictionary<string, string>>(ReferenceEqualityComparer.Instance);
827string GetKey(JsonObject obj, string key)
852void IndexProperties(JsonObject obj, string? prefix)
862if (property.Value is JsonObject section)
877var parent = settings;
887if (child is not JsonObject section)
907if (value is JsonObject section)
917private readonly record struct SettingsProperty(JsonObject Parent, string Key);
Aspire.Cli.EndToEnd.Tests (66)
Aspire.Cli.Tests (273)
Aspire.Dashboard (22)
Aspire.Dashboard.Tests (10)
Aspire.Hosting (187)
Pipelines\Internal\DeploymentStateManagerBase.cs (19)
37private JsonObject? _state;
56JsonObject state,
58JsonObject? originalSectionData,
64protected virtual JsonNode? GetSectionState(JsonObject? state, string sectionName, bool includeLegacyState) =>
72protected async Task<JsonObject> LoadStateAsync(CancellationToken cancellationToken = default)
96protected virtual Task<JsonObject> LoadStateFromStorageAsync(CancellationToken cancellationToken = default) =>
102protected static async Task<JsonObject> LoadStateFileAsync(string? statePath, CancellationToken cancellationToken)
113protected static JsonObject LoadStateFile(string? statePath)
121private static JsonObject ParseStateFile(string? fileContent)
134if (JsonNode.Parse(fileContent, documentOptions: jsonDocumentOptions) is not JsonObject flattenedState)
143public async Task SaveStateAsync(JsonObject state, CancellationToken cancellationToken = default)
187JsonObject? data = null;
191if (sectionData is JsonObject o)
222protected static JsonNode? TryGetNestedPropertyValue(JsonObject? node, string path)
234if (current is not JsonObject currentObj || !currentObj.TryGetPropertyValue(segment, out var nextNode))
324protected static void SetNestedPropertyValue(JsonObject root, string path, JsonObject? value)
328var current = root;
332if (!current.TryGetPropertyValue(segment, out var nextNode) || nextNode is not JsonObject nextObj)
Pipelines\Internal\FileDeploymentStateManager.cs (68)
30private JsonObject _currentState = [];
31private JsonObject _legacyState = [];
32private JsonObject _legacyStateSnapshot = [];
88internal static async Task<JsonObject> LoadEffectiveStateAsync(
93JsonObject currentState;
116JsonObject legacyState = [];
138var effectiveState = MergeState(MergeState(legacyStateSnapshot, legacyState), currentState);
144internal static JsonObject LoadEffectiveState(string canonicalStatePath, string? legacyStatePath)
146JsonObject currentState;
168JsonObject legacyState = [];
187var effectiveState = MergeState(MergeState(legacyStateSnapshot, legacyState), currentState);
227protected override async Task<JsonObject> LoadStateFromStorageAsync(CancellationToken cancellationToken = default)
268protected override JsonNode? GetSectionState(JsonObject? state, string sectionName, bool includeLegacyState)
286if (mergedSection is not JsonObject mergedObject)
305JsonObject state,
307JsonObject? originalSectionData,
346var sectionData = TryGetNestedPropertyValue(state, sectionName) as JsonObject;
348var latestEffectiveState = MergeState(GetLegacyFallbackState(), _currentState);
350var latestSectionData = NormalizeSectionData(
352var desiredSectionData = ApplyChanges(latestSectionData, originalSectionData, sectionData) as JsonObject;
378private static JsonObject? NormalizeSectionData(JsonNode? sectionData) =>
381JsonObject sectionObject => sectionObject,
428private static JsonObject MergeState(JsonObject legacyState, JsonObject currentState)
430var mergedState = legacyState.DeepClone().AsObject();
434static void MergeInto(JsonObject target, JsonObject source)
438if (sourceValue is JsonObject sourceObject &&
439target[name] is JsonObject targetObject)
451private JsonObject GetLegacyFallbackState() =>
454private static async Task WriteStateAsync(string statePath, JsonObject state, CancellationToken cancellationToken)
456var flattenedSecrets = JsonFlattener.FlattenJsonObject(state);
497JsonObject currentState,
517if (baseline is JsonObject baselineObject && value is JsonObject valueObject)
547if (originalValue is JsonObject originalObject &&
548savedValue is JsonObject savedObject &&
551(latestValue is not JsonObject latestObject || !IsScalarSectionData(latestObject)))
553var result = latestValue?.DeepClone() as JsonObject ?? [];
597if (savedValue is JsonObject savedObject &&
598(originalValue is JsonObject || !originalExists) &&
600(originalValue is not JsonObject originalObject || !IsScalarSectionData(originalObject)) &&
601(latestValue is not JsonObject latestObject || !IsScalarSectionData(latestObject)))
603return (true, ApplyChanges(latestValue, originalValue as JsonObject ?? [], savedObject));
612private static bool IsScalarSectionData(JsonObject value) => value.ContainsKey(string.Empty);
618JsonObject effectiveState,
619JsonObject currentState,
639private static bool NestedPropertyExists(JsonObject root, string path)
642JsonObject current = root;
646nextNode is not JsonObject nextObject)
657private static void SetNestedNodeValue(JsonObject root, string path, JsonNode? value, bool valueExists)
660var current = root;
664if (!current.TryGetPropertyValue(segment, out var nextNode) || nextNode is not JsonObject nextObject)
702var legacyStateSnapshot = migrationState.LegacyStateSnapshot;
731var migrationState = await LoadStateFileAsync(migrationStatePath, cancellationToken).ConfigureAwait(false);
743private static MigrationState ParseMigrationState(JsonObject migrationState)
746var legacyStateSnapshot = migrationState[LegacyStateProperty] switch
749JsonObject legacyState => legacyState,
758var currentState = migrationState[CurrentStateProperty] switch
794JsonObject currentState,
795JsonObject legacyStateSnapshot,
800var migrationState = new JsonObject
814JsonObject LegacyStateSnapshot,
816JsonObject? CurrentState);
Aspire.Hosting.Azure (64)
AzureProvisioningController.cs (17)
2527var json = await CreateCommandResultJsonAsync(commandName, resourceName: null, cancellationToken).ConfigureAwait(false);
2548var json = await CreateCommandResultJsonAsync(DeleteAzureResourcesCommandName, resourceName: null, cancellationToken).ConfigureAwait(false);
2567var json = await CreateResourceCommandResultJsonAsync(DeleteAzureResourceCommandName, model, resourceName, cancellationToken).ConfigureAwait(false);
2579private async Task<JsonObject> CreateResourceCommandResultJsonAsync(string commandName, DistributedApplicationModel model, string resourceName, CancellationToken cancellationToken)
2581var json = await CreateCommandResultJsonAsync(commandName, resourceName, cancellationToken).ConfigureAwait(false);
2602var json = await CreateCommandResultJsonAsync(GetAzureResourceCommandName, resourceName, cancellationToken).ConfigureAwait(false);
2614var deployment = await CreateCachedDeploymentStateInfoAsync(bicepResource, context, cancellationToken).ConfigureAwait(false);
2625private async Task<JsonObject> CreateCachedDeploymentStateInfoAsync(AzureBicepResource resource, AzureContextState context, CancellationToken cancellationToken)
2636var json = new JsonObject
2668private async Task<JsonObject> CreateLiveResourceInfoAsync(string? resourceId, AzureContextState context, CancellationToken cancellationToken)
2672var json = new JsonObject
2776if (outputs is not JsonObject outputsObject ||
2778outputNode is not JsonObject outputObject ||
2787private async Task<JsonObject> CreateCommandResultJsonAsync(string commandName, string? resourceName, CancellationToken cancellationToken)
2793var json = new JsonObject
2827private static CommandResultData CreateJsonResultData(JsonObject json, bool displayImmediately = false) =>
2847var json = new JsonObject
Provisioning\BicepUtilities.cs (7)
40public static async Task SetParametersAsync(JsonObject parameters, AzureBicepResource resource, DistributedApplicationExecutionContext executionContext, bool skipKnownValues = false, CancellationToken cancellationToken = default)
95public static async Task SetScopeAsync(JsonObject scope, AzureBicepResource resource, CancellationToken cancellationToken = default)
122public static string GetChecksum(AzureBicepResource resource, JsonObject parameters, JsonObject? scope)
152var parameters = JsonNode.Parse(jsonString)?.AsObject();
153var scope = section.Data[DeploymentStateScopeKey]?.GetValue<string>() is { Length: > 0 } scopeString
206private static async Task SetScopeValueAsync(JsonObject scope, string propertyName, object? value, CancellationToken cancellationToken)
Provisioning\Provisioners\BicepProvisioner.cs (12)
350JsonObject? outputs,
354if (!TryGetDeploymentStateJsonObject(stateSection, BicepUtilities.DeploymentStateParametersKey, resource.Name, out var parameters) ||
368var scope = TryGetDeploymentStateJsonObject(stateSection, BicepUtilities.DeploymentStateScopeKey, resource.Name, out var cachedScope)
470[NotNullWhen(true)] out JsonObject? value)
565var parameters = new JsonObject();
568var scope = new JsonObject();
793var outputObj = outputs?.ToObjectFromJson<JsonObject>();
1321JsonObject parameters,
1322JsonObject? outputObj,
1323JsonObject? scope,
Aspire.Hosting.Azure.EntraId.Tests (1)
Aspire.Hosting.Azure.Kubernetes (3)
Aspire.Hosting.Azure.Kubernetes.Tests (4)
Aspire.Hosting.Azure.Sandboxes (18)
Aspire.Hosting.Azure.Tests (110)
Aspire.Hosting.Azure.WebPubSub (2)
Aspire.Hosting.Blazor (2)
Aspire.Hosting.Browsers.Tests (1)
Aspire.Hosting.CodeGeneration.Go (15)
Aspire.Hosting.CodeGeneration.Go.Tests (1)
Aspire.Hosting.CodeGeneration.Java (3)
Aspire.Hosting.CodeGeneration.Java.Tests (1)
Aspire.Hosting.CodeGeneration.Python (3)
Aspire.Hosting.CodeGeneration.TypeScript (21)
Aspire.Hosting.CodeGeneration.TypeScript.Tests (19)
Aspire.Hosting.Docker.Tests (3)
Aspire.Hosting.Kubernetes (2)
Aspire.Hosting.Kubernetes.Tests (3)
Aspire.Hosting.Native.Client (4)
Aspire.Hosting.Native.CodeGeneration (4)
Aspire.Hosting.Native.Core.Tests (55)
NativeRpcTests.cs (4)
43var wait = client.Invoke("waitFor", Arguments(("context", web), ("dependency", cache)));
162var duplicate = client.Invoke("addResource", Arguments(("context", composition),
208var rejected = client.Invoke("addResource", Arguments(("context", composition),
223private static string Error(JsonObject response) =>
Aspire.Hosting.Native.Server (79)
Rpc\NativeProviderRegistry.cs (22)
21JsonObject InspectCapabilities();
22Task<JsonNode?> InvokeAsync(NativeRpcConnection caller, string capability, JsonObject arguments);
23Task<JsonNode?> InvokeCoreAsync(NativeRpcConnection provider, string capability, JsonObject arguments);
24Task<JsonNode?> InvokeCallbackAsync(NativeRpcConnection provider, string callback, JsonObject arguments);
28internal sealed partial class NativeProviderRegistry(JsonObject coreContract, NativeServerOptions options, ILogger logger) : INativeProviderRegistry
178public JsonObject InspectCapabilities()
191public async Task<JsonNode?> InvokeAsync(NativeRpcConnection caller, string capability, JsonObject arguments)
212var mapped = new JsonObject();
281public async Task<JsonNode?> InvokeCoreAsync(NativeRpcConnection provider, string capability, JsonObject arguments)
296if (value is JsonObject handle && handle.ContainsKey("$handle"))
324JsonObject obj => new JsonObject(obj.Select(pair => KeyValuePair.Create(pair.Key, Translate(pair.Value)))),
329var translated = (JsonObject)Translate(arguments)!;
339if (value is JsonObject handle && handle.ContainsKey("$handle"))
348JsonObject obj => new JsonObject(obj.Select(pair => KeyValuePair.Create(pair.Key, DelegateResult(pair.Value)))),
355public async Task<JsonNode?> InvokeCallbackAsync(NativeRpcConnection provider, string callbackId, JsonObject arguments)
370var mapped = new JsonObject();
390var handle = value as JsonObject ?? throw RpcFault.InvalidHandle("A typed handle is required.");
537internal sealed record DelegatedCoreReference(NativeRpcConnection Owner, JsonObject Handle) : ICapabilityLifetime
543JsonObject Handle, JsonObject Lifetime, NativeProviderRegistry.PublishedResource Resource) : ICapabilityLifetime
Aspire.Hosting.Radius (4)
Aspire.Hosting.RemoteHost (61)
Ats\AtsCallbackProxyFactory.cs (17)
158var jsonObjectType = typeof(JsonObject);
218argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
234argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
250argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
266argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
272private void InvokeSyncVoid(string callbackId, JsonObject? args, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
278private void InvokeSyncVoidWithDtoWriteback(string callbackId, JsonObject? args, object?[] originalArgs, Type[] argTypes, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
285private T? InvokeSyncResult<T>(string callbackId, JsonObject? args, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
292private async Task InvokeAsyncVoid(string callbackId, JsonObject? args, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
298private async Task InvokeAsyncVoidWithDtoWriteback(string callbackId, JsonObject? args, object?[] originalArgs, Type[] argTypes, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
305private async Task<T?> InvokeAsyncResult<T>(string callbackId, JsonObject? args, CancellationToken cancellationToken, int ctParamIndex, TimeSpan? timeout)
312private Task<JsonNode?> InvokeCallbackAsync(string callbackId, JsonObject? args, CancellationToken cancellationToken, TimeSpan? timeout)
337private void AddCancellationTokenToArgs(ref JsonObject? args, CancellationToken cancellationToken, int ctParamIndex)
370argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
390argsExpr ?? Expression.Constant(null, typeof(JsonObject)),
422if (result is not JsonObject returnedArgs)
450if (returnedArgs[key] is JsonObject modifiedDto)
Ats\CapabilityDispatcher.cs (15)
22JsonObject? args,
549string capabilityId, JsonObject? args, JsonRpcCallbackInvoker? ownerInvoker = null, CancellationToken cancellationToken = default)
653public JsonNode? Invoke(string capabilityId, JsonObject? args)
786JsonObject? args,
829JsonObject? args,
987JsonObject obj when obj.ContainsKey("$handle") => "handle",
988JsonObject => "object",
996JsonObject? args,
1058public static string GetRequiredString(this JsonObject args, string name, string capabilityId)
1072public static string? GetOptionalString(this JsonObject args, string name)
1084public static int? GetOptionalInt(this JsonObject args, string name)
1097this JsonObject args,
1127public static T? GetDto<T>(this JsonObject args, string name) where T : class
1129if (args.TryGetPropertyValue(name, out var node) && node is JsonObject obj)
1139public static JsonObject CreateHandleResult(this HandleRegistry handles, object obj, string typeId)
Ats\ExternalCapabilityRegistry.cs (5)
445string capabilityId, JsonObject? args, JsonRpcCallbackInvoker? ownerInvoker = null, CancellationToken cancellationToken = default)
467var forwardedArgs = args?.DeepClone().AsObject();
552internal async Task<JsonNode?> InvokeGuestCallbackAsync(JsonRpc host, string callbackId, JsonObject? args, CancellationToken cancellationToken)
598internal CancellationToken[] GetCancellationTokens(string capabilityId, JsonObject? args, AtsMarshaller marshaller)
634private void RegisterCallbackOwners(ExternalCapabilityRegistration registration, JsonObject? args, JsonRpcCallbackInvoker? ownerInvoker, string invocationId)
Aspire.Hosting.RemoteHost.Tests (208)
TestServices\IntegrationHostTestConnection.cs (5)
22public IntegrationHostTestConnection(JsonElement capabilities, Func<string, JsonObject?, Task<JsonNode?>> handleCapability)
27public IntegrationHostTestConnection(JsonElement capabilities, Func<string, JsonObject?, CancellationToken, Task<JsonNode?>> invokeCallback)
39Func<string, JsonObject?, Task<JsonNode?>>? handleCapability,
40Func<string, JsonObject?, CancellationToken, Task<JsonNode?>>? invokeCallback)
52(string capabilityId, JsonObject? args, string invocationId) =>
Aspire.Hosting.Tests (37)
Aspire.Hosting.TestUtilities (1)
Aspire.Hosting.Yarp (5)
ConfigurationSchemaGenerator (23)
ConfigSchemaEmitter.cs (23)
44var root = new JsonObject();
51private void GenerateLogCategories(JsonObject parent)
59var propertiesNode = new JsonObject(s_ignoreCaseNodeOptions);
62var categoryNode = new JsonObject();
76private void GenerateGraph(JsonObject rootNode)
101private bool GeneratePathSegment(JsonObject currentNode, TypeSpec type, Queue<string> pathSegments)
123if (currentNode[propertiesName] is not JsonObject propertiesNode)
132if (propertiesNode[pathSegment] is not JsonObject pathSegmentNode)
182private bool GenerateType(JsonObject currentNode, TypeSpec type)
226private bool GenerateObject(JsonObject currentNode, ObjectSpec objectSpec)
244if (currentNode["properties"] is not JsonObject propertiesNode)
275private bool GenerateProperty(JsonObject currentNode, PropertySpec property, IPropertySymbol? propertySymbol)
286var propertyNode = new JsonObject();
306private bool GenerateCollection(JsonObject currentNode, CollectionSpec collection, string typeName, string containerName)
319var containerNode = new JsonObject();
334private static void RestoreBackup(JsonNode? backupNode, string name, JsonObject parentNode)
434private static void GenerateDescriptionFromDocComment(JsonObject propertyNode, string docComment)
490private void GenerateDescriptionForType(JsonObject currentNode, TypeSpec type)
587private void GenerateParsableFromString(JsonObject propertyNode, ParsableFromStringSpec parsable)
678private bool IsExcluded(JsonObject currentNode, PropertySpec property)
718private static void ReplaceNodeWithKeyCasingChange(JsonObject jsonObject, string key, JsonNode value)
739case JsonObject obj:
743obj.Parent is JsonObject && obj.GetPropertyName() == "properties" ?
dotnet-user-jwts (19)
GenerateTemplateManifest (6)
Infrastructure.Tests (105)
Microsoft.AspNetCore.JsonPatch.SystemTextJson (13)
Microsoft.AspNetCore.OpenApi (10)
Microsoft.Extensions.AI (4)
Microsoft.Extensions.AI.Abstractions (29)
Microsoft.Extensions.AI.Abstractions.Tests (8)
Microsoft.Extensions.AI.Evaluation.Safety (9)
Microsoft.Extensions.AI.OpenAI (2)
Microsoft.ML.AutoML (1)
Microsoft.ML.AutoML.SourceGenerator (1)
Microsoft.NET.Build.Containers (16)
Microsoft.NET.Build.Tasks (12)
Microsoft.NETCore.Platforms (1)
Microsoft.TemplateEngine.Cli (23)
Microsoft.TemplateEngine.Edge (59)
parent\Shared\JExtensions.cs (33)
44if (token is not JsonObject obj)
156if (token is not JsonObject obj)
197internal static IReadOnlyList<string> ToStringReadOnlyList(this JsonObject jObject, string propertyName, IReadOnlyList<string>? defaultValue = null)
210if (token is not JsonObject obj)
222return element is not JsonObject jObj ? [] : GetObjectProperties(jObj);
228/// Enumerates the properties of a <see cref="JsonObject"/>, handling duplicate keys gracefully.
231/// <see cref="JsonObject"/> lazily initializes its internal dictionary when first accessed.
236private static IReadOnlyList<KeyValuePair<string, JsonNode?>> GetObjectProperties(JsonObject obj)
251/// Enumerates the properties of a <see cref="JsonObject"/> by re-parsing its JSON text via
255/// <see cref="JsonObject.WriteTo"/> falls back to the underlying <see cref="System.Text.Json.JsonElement"/>
257/// safe to call even after a failed <see cref="JsonObject"/> initialization.
260private static List<KeyValuePair<string, JsonNode?>> GetObjectPropertiesViaDocument(JsonObject obj)
285if (token is not JsonObject obj || key == null)
439internal static JsonObject ReadJObjectFromIFile(this IFile file)
444return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
448internal static JsonObject ReadObject(this IPhysicalFileSystem fileSystem, string path)
453return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
507/// Tries to get a property value from a <see cref="JsonObject"/> using case-insensitive key matching.
509internal static bool TryGetValueCaseInsensitive(this JsonObject obj, string key, out JsonNode? result)
519internal static JsonNode? GetPropertyCaseInsensitive(JsonObject obj, string key)
552private static JsonNode? GetPropertyCaseInsensitiveViaDocument(JsonObject obj, string key)
580internal static JsonObject ParseJsonObject(string json)
582return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
602internal static JsonObject FromObject(object obj)
605return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
610/// Creates a deep clone of a <see cref="JsonObject"/> by round-tripping through JSON text.
612internal static JsonObject DeepCloneObject(this JsonObject source)
614return (JsonObject?)JsonNode.Parse(source.ToJsonString(), null, DocOptions)
625internal static void Merge(this JsonObject target, JsonObject source)
629if (property.Value is JsonObject sourceObj
631&& targetNode is JsonObject targetObj)
Settings\TemplateCache.cs (6)
63(string, JsonObject?)? hostFile = GetBestHostConfigMatch(chosenTemplate.Template, environmentSettings, chosenTemplate.MountPoint);
76public TemplateCache(JsonObject? contentJObject)
97if (contentJObject.TryGetValueCaseInsensitive(nameof(MountPointsInfo), out JsonNode? mountPointInfoToken) && mountPointInfoToken is JsonObject mountPointInfoObj)
116if (entry is JsonObject entryObj)
286private (string, JsonObject?)? GetBestHostConfigMatch(IScanTemplateInfo newTemplate, IEngineEnvironmentSettings settings, IMountPoint mountPoint)
303private JsonObject? ReadHostFile(IScanTemplateInfo template, string path, IEngineEnvironmentSettings settings, IMountPoint mountPoint)
Microsoft.TemplateEngine.Orchestrator.RunnableProjects (103)
parent\Shared\JExtensions.cs (33)
44if (token is not JsonObject obj)
156if (token is not JsonObject obj)
197internal static IReadOnlyList<string> ToStringReadOnlyList(this JsonObject jObject, string propertyName, IReadOnlyList<string>? defaultValue = null)
210if (token is not JsonObject obj)
222return element is not JsonObject jObj ? [] : GetObjectProperties(jObj);
228/// Enumerates the properties of a <see cref="JsonObject"/>, handling duplicate keys gracefully.
231/// <see cref="JsonObject"/> lazily initializes its internal dictionary when first accessed.
236private static IReadOnlyList<KeyValuePair<string, JsonNode?>> GetObjectProperties(JsonObject obj)
251/// Enumerates the properties of a <see cref="JsonObject"/> by re-parsing its JSON text via
255/// <see cref="JsonObject.WriteTo"/> falls back to the underlying <see cref="System.Text.Json.JsonElement"/>
257/// safe to call even after a failed <see cref="JsonObject"/> initialization.
260private static List<KeyValuePair<string, JsonNode?>> GetObjectPropertiesViaDocument(JsonObject obj)
285if (token is not JsonObject obj || key == null)
439internal static JsonObject ReadJObjectFromIFile(this IFile file)
444return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
448internal static JsonObject ReadObject(this IPhysicalFileSystem fileSystem, string path)
453return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
507/// Tries to get a property value from a <see cref="JsonObject"/> using case-insensitive key matching.
509internal static bool TryGetValueCaseInsensitive(this JsonObject obj, string key, out JsonNode? result)
519internal static JsonNode? GetPropertyCaseInsensitive(JsonObject obj, string key)
552private static JsonNode? GetPropertyCaseInsensitiveViaDocument(JsonObject obj, string key)
580internal static JsonObject ParseJsonObject(string json)
582return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
602internal static JsonObject FromObject(object obj)
605return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
610/// Creates a deep clone of a <see cref="JsonObject"/> by round-tripping through JSON text.
612internal static JsonObject DeepCloneObject(this JsonObject source)
614return (JsonObject?)JsonNode.Parse(source.ToJsonString(), null, DocOptions)
625internal static void Merge(this JsonObject target, JsonObject source)
629if (property.Value is JsonObject sourceObj
631&& targetNode is JsonObject targetObj)
Microsoft.TemplateEngine.Utils (33)
parent\Shared\JExtensions.cs (33)
44if (token is not JsonObject obj)
156if (token is not JsonObject obj)
197internal static IReadOnlyList<string> ToStringReadOnlyList(this JsonObject jObject, string propertyName, IReadOnlyList<string>? defaultValue = null)
210if (token is not JsonObject obj)
222return element is not JsonObject jObj ? [] : GetObjectProperties(jObj);
228/// Enumerates the properties of a <see cref="JsonObject"/>, handling duplicate keys gracefully.
231/// <see cref="JsonObject"/> lazily initializes its internal dictionary when first accessed.
236private static IReadOnlyList<KeyValuePair<string, JsonNode?>> GetObjectProperties(JsonObject obj)
251/// Enumerates the properties of a <see cref="JsonObject"/> by re-parsing its JSON text via
255/// <see cref="JsonObject.WriteTo"/> falls back to the underlying <see cref="System.Text.Json.JsonElement"/>
257/// safe to call even after a failed <see cref="JsonObject"/> initialization.
260private static List<KeyValuePair<string, JsonNode?>> GetObjectPropertiesViaDocument(JsonObject obj)
285if (token is not JsonObject obj || key == null)
439internal static JsonObject ReadJObjectFromIFile(this IFile file)
444return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
448internal static JsonObject ReadObject(this IPhysicalFileSystem fileSystem, string path)
453return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
507/// Tries to get a property value from a <see cref="JsonObject"/> using case-insensitive key matching.
509internal static bool TryGetValueCaseInsensitive(this JsonObject obj, string key, out JsonNode? result)
519internal static JsonNode? GetPropertyCaseInsensitive(JsonObject obj, string key)
552private static JsonNode? GetPropertyCaseInsensitiveViaDocument(JsonObject obj, string key)
580internal static JsonObject ParseJsonObject(string json)
582return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
602internal static JsonObject FromObject(object obj)
605return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
610/// Creates a deep clone of a <see cref="JsonObject"/> by round-tripping through JSON text.
612internal static JsonObject DeepCloneObject(this JsonObject source)
614return (JsonObject?)JsonNode.Parse(source.ToJsonString(), null, DocOptions)
625internal static void Merge(this JsonObject target, JsonObject source)
629if (property.Value is JsonObject sourceObj
631&& targetNode is JsonObject targetObj)
Microsoft.TemplateSearch.Common (71)
parent\Shared\JExtensions.cs (33)
44if (token is not JsonObject obj)
156if (token is not JsonObject obj)
197internal static IReadOnlyList<string> ToStringReadOnlyList(this JsonObject jObject, string propertyName, IReadOnlyList<string>? defaultValue = null)
210if (token is not JsonObject obj)
222return element is not JsonObject jObj ? [] : GetObjectProperties(jObj);
228/// Enumerates the properties of a <see cref="JsonObject"/>, handling duplicate keys gracefully.
231/// <see cref="JsonObject"/> lazily initializes its internal dictionary when first accessed.
236private static IReadOnlyList<KeyValuePair<string, JsonNode?>> GetObjectProperties(JsonObject obj)
251/// Enumerates the properties of a <see cref="JsonObject"/> by re-parsing its JSON text via
255/// <see cref="JsonObject.WriteTo"/> falls back to the underlying <see cref="System.Text.Json.JsonElement"/>
257/// safe to call even after a failed <see cref="JsonObject"/> initialization.
260private static List<KeyValuePair<string, JsonNode?>> GetObjectPropertiesViaDocument(JsonObject obj)
285if (token is not JsonObject obj || key == null)
439internal static JsonObject ReadJObjectFromIFile(this IFile file)
444return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
448internal static JsonObject ReadObject(this IPhysicalFileSystem fileSystem, string path)
453return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
507/// Tries to get a property value from a <see cref="JsonObject"/> using case-insensitive key matching.
509internal static bool TryGetValueCaseInsensitive(this JsonObject obj, string key, out JsonNode? result)
519internal static JsonNode? GetPropertyCaseInsensitive(JsonObject obj, string key)
552private static JsonNode? GetPropertyCaseInsensitiveViaDocument(JsonObject obj, string key)
580internal static JsonObject ParseJsonObject(string json)
582return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
602internal static JsonObject FromObject(object obj)
605return (JsonObject?)JsonNode.Parse(json, null, DocOptions)
610/// Creates a deep clone of a <see cref="JsonObject"/> by round-tripping through JSON text.
612internal static JsonObject DeepCloneObject(this JsonObject source)
614return (JsonObject?)JsonNode.Parse(source.ToJsonString(), null, DocOptions)
625internal static void Merge(this JsonObject target, JsonObject source)
629if (property.Value is JsonObject sourceObj
631&& targetNode is JsonObject targetObj)
TemplateDiscoveryMetadata\LegacySearchCacheReader.cs (12)
61JsonObject cacheObject = JExtensions.ParseJsonObject(cacheText);
66internal static bool TryReadDiscoveryMetadata(JsonObject cacheObject, ILogger logger, IReadOnlyDictionary<string, Func<object, object>>? additionalDataReaders, out TemplateDiscoveryMetadata? discoveryMetadata)
81private static bool TryReadVersion(ILogger logger, JsonObject cacheObject, out string? version)
97JsonObject cacheObject,
112if (entry is JsonObject entryObj)
143private static bool TryReadPackToTemplateMap(ILogger logger, JsonObject cacheObject, out IReadOnlyDictionary<string, PackToTemplateEntry>? packToTemplateMap)
149if (packToTemplateMapToken is not JsonObject packToTemplateMapObject)
163JsonObject entryValue = (JsonObject)packEntry.Value;
208private static bool TryReadAdditionalData(ILogger logger, JsonObject cacheObject, IReadOnlyDictionary<string, Func<object, object>>? additionalDataReaders, out IReadOnlyDictionary<string, object>? additionalData)
218if (additionalDataToken is not JsonObject additionalDataObject)
233if (dataNode is not JsonObject dataObject)
MSBuild (5)
NativeIntegrations.DockerCompose (96)
ComposeModels.cs (25)
23internal JsonObject ToJson()
25var result = new JsonObject();
42var exposure = new JsonObject { ["endpoint"] = port.Endpoint, ["hostIp"] = port.HostIp };
66public sealed record DockerComposePlan(JsonObject Compose, JsonObject Inputs, List<ComposePlannedService> Services);
73public JsonObject Model { get; }
75internal ComposeServiceBuilder(JsonObject model, string applicationDirectory, Func<string, string>? render = null)
97get => Model["build"] is JsonObject build ? new(build["context"]!.GetValue<string>(), build["dockerfile"]!.GetValue<string>()) : null;
103get => Model["healthcheck"] is JsonObject health ? ComposeJson.ReadHealthcheck(health) : null;
164public sealed class ComposeFileBuilder(JsonObject model, string applicationDirectory)
166public JsonObject Model { get; } = model;
187var services = Model["services"]!.AsObject();
192var service = new JsonObject { ["image"] = ComposeJson.Literal(image), ["labels"] = new JsonObject() };
203public void AddNetwork(string name, JsonObject options) => Add("networks", name, ComposeJson.Escape(options));
206var volume = new JsonObject();
221var secret = new JsonObject { ["external"] = true };
228private void Add(string collection, string name, JsonObject value)
235public sealed class CapturedEnvironmentVariable(JsonObject model)
304internal static JsonObject BuildPaths(ComposeBuild build, string applicationDirectory)
316internal static JsonObject Healthcheck(ComposeHealthcheck value, bool escape = false)
323var result = new JsonObject { ["test"] = Strings(value.Test.Select(part => escape ? Literal(Text(part, true)) : Text(part, true))) };
344internal static ComposeHealthcheck ReadHealthcheck(JsonObject value) => new(
348internal static JsonObject Escape(JsonObject source) => EscapeNode(source)!.AsObject();
351JsonObject obj => new JsonObject(obj.Select(pair => KeyValuePair.Create(pair.Key, EscapeNode(pair.Value)))),
DockerComposeGenerator.cs (55)
40var environment = environments.SingleOrDefault(resource => Text(resource, "name") == name);
45var resources = new Dictionary<string, JsonObject>(StringComparer.Ordinal);
47var options = new Dictionary<string, JsonObject>(StringComparer.Ordinal);
49foreach (var resource in all.OrderBy(resource => Text(resource, "name"), StringComparer.Ordinal))
60var configuration = Options(resource);
102var inputs = new JsonObject
108var compose = new JsonObject { ["name"] = project, ["services"] = new JsonObject() };
114var configuration = options[resourceName];
132var service = new JsonObject
136if (configuration["build"] is JsonObject build)
160foreach (var endpoint in endpoints)
192var exposure = new JsonObject { ["endpoint"] = Text(endpoint, "name") };
200foreach (var exposure in exposures.OrderBy(value => Text(value, "endpoint"), StringComparer.Ordinal))
202var endpoint = endpoints.SingleOrDefault(endpoint => Text(endpoint, "name") == Text(exposure, "endpoint"))
211var value = new JsonObject { ["target"] = exposure.Target };
234var captured = (inputs["environment"] ??= new JsonObject()).AsObject();
277if (configuration["healthcheck"] is JsonObject healthcheck)
307JsonObject Normalize(JsonObject value, int depth = 0)
339string Render(JsonObject value)
371public static IReadOnlyDictionary<string, string> ResolveInputs(DockerComposePlan plan, JsonObject model,
375foreach (var parameter in Objects(plan.Inputs["parameters"]))
387var entry = node!.AsObject();
402internal static void CaptureParameters(DockerComposePlan plan, JsonObject model)
404foreach (var parameter in Objects(plan.Inputs["parameters"]))
408var captured = (plan.Inputs["environment"] ??= new JsonObject()).AsObject();
414var entry = new JsonObject { ["description"] = $"Deployment parameter {name}", ["secret"] = secret };
423private static void ConfigureEnvironment(DockerComposePlan plan, JsonObject environment)
426var configuration = source is null ? new JsonObject
429} : JsonNode.Parse(source) as JsonObject ?? throw new ArgumentException("Docker Compose environment configuration must be an object.");
462var services = plan.Compose["services"]!.AsObject();
472var variables = new JsonObject
482var dashboard = new JsonObject
501var captured = (plan.Inputs["environment"] ??= new JsonObject()).AsObject();
512internal static JsonObject Options(JsonObject resource)
514var options = resource["configuration"]?["publish.dockerCompose"] is { } source ? JsonNode.Parse(source.GetValue<string>())!.AsObject() : new JsonObject();
519internal static void ValidateOptions(JsonObject options)
535var build = options["build"]?.AsObject() ?? throw new ArgumentException("Build configuration must be an object.", nameof(options));
542var health = options["healthcheck"]?.AsObject() ?? throw new ArgumentException("Healthcheck must be an object.", nameof(options));
549foreach (var exposure in Objects(options["ports"]))
569internal static IEnumerable<JsonObject> Objects(JsonNode? value) => (value ?? throw new ArgumentException("Expected a JSON array.")).AsArray().Select(node => node!.AsObject());
571internal static string Text(JsonObject value, string property) => value[property]?.GetValue<string>() ?? throw new ArgumentException($"Missing string '{property}'.");
572internal static bool Boolean(JsonObject value, string property) => value[property]?.GetValue<bool>() ?? false;
573private static int Integer(JsonObject value, string property) => value[property]!.GetValue<int>();
594private static void Fields(JsonObject value, string[] allowed)
608private static bool ContainsParameter(JsonObject value) => Text(value, "kind") switch
615private static string Evaluate(JsonObject value, IReadOnlyDictionary<string, JsonObject> resources,
630private static string EndpointValue(JsonObject value, IReadOnlyDictionary<string, JsonObject> resources, IReadOnlyDictionary<string, string> names)
633if (!resources.TryGetValue(name, out var resource) || !names.TryGetValue(name, out var host))
637var endpoint = Objects(resource["endpoints"]).SingleOrDefault(endpoint => Text(endpoint, "name") == Text(value, "endpoint"))
651private static void ValidateDependencies(IReadOnlyDictionary<string, JsonObject> resources)
666if (!resources.TryGetValue(name, out var resource))
NuGet.Protocol (11)
sdk-tasks (7)
SelectTests (2)
Shared.Tests (2)
System.Text.Json (81)
TestProject.AppHost (3)