546 references to RootElement
aspire (53)
Acquisition\InstallSidecarReader.cs (7)
158if (doc.RootElement.ValueKind != JsonValueKind.Object)
164Source: ReadOptionalString(doc.RootElement, "source"),
165Channel: ReadOptionalString(doc.RootElement, "channel"),
166Version: ReadOptionalString(doc.RootElement, "version"),
167Commit: ReadOptionalString(doc.RootElement, "commit"),
168NuGetServiceIndexOverride: ReadOptionalString(doc.RootElement, "nugetServiceIndexOverride"),
169Packages: ReadOptionalString(doc.RootElement, "packages"));
aspire-managed (3)
Aspire.Acquisition.Tests (10)
Aspire.Cli.EndToEnd.Tests (23)
Aspire.Cli.Tests (132)
Commands\LsCommandTests.cs (17)
160Assert.Equal(JsonValueKind.Array, document.RootElement.ValueKind);
161Assert.Equal(0, document.RootElement.GetArrayLength());
243Assert.Equal(JsonValueKind.Array, document.RootElement.ValueKind);
244Assert.Equal(2, document.RootElement.GetArrayLength());
275Assert.Equal(JsonValueKind.Array, document.RootElement.ValueKind);
276Assert.Equal(0, document.RootElement.GetArrayLength());
319Assert.Equal(JsonValueKind.Object, document.RootElement.ValueKind);
323Assert.Equal(appHostPath1, firstCandidate.RootElement.GetProperty("path").GetString());
324Assert.Equal(KnownLanguageId.CSharp, firstCandidate.RootElement.GetProperty("language").GetString());
325Assert.Equal("buildable", firstCandidate.RootElement.GetProperty("status").GetString());
328Assert.Equal(appHostPath2, secondCandidate.RootElement.GetProperty("path").GetString());
329Assert.Equal(KnownLanguageId.TypeScript, secondCandidate.RootElement.GetProperty("language").GetString());
330Assert.Equal("possibly-unbuildable", secondCandidate.RootElement.GetProperty("status").GetString());
406Assert.Equal(appHostPathZ, first.RootElement.GetProperty("path").GetString());
407Assert.Equal(appHostPathA, second.RootElement.GetProperty("path").GetString());
408Assert.Equal(appHostPathM, third.RootElement.GetProperty("path").GetString());
449Assert.Equal(appHostPath, candidate.RootElement.GetProperty("path").GetString());
Aspire.Components.Common.TestUtilities (2)
Aspire.Dashboard (12)
Model\GenAI\GenAIMessages.cs (12)
214if (!doc.RootElement.TryGetProperty("type", out var typeProp))
223MessagePart.TextType => doc.RootElement.Deserialize<TextPart>(options),
224MessagePart.ToolCallType => TryParseStringArguments(doc.RootElement.Deserialize<ToolCallRequestPart>(options)),
225MessagePart.ToolCallResponseType => doc.RootElement.Deserialize<ToolCallResponsePart>(options),
226MessagePart.BlobType => doc.RootElement.Deserialize<BlobPart>(options),
227MessagePart.FileType => doc.RootElement.Deserialize<FilePart>(options),
228MessagePart.UriType => doc.RootElement.Deserialize<UriPart>(options),
229MessagePart.ReasoningType => doc.RootElement.Deserialize<ReasoningPart>(options),
230MessagePart.ServerToolCallType => TryParseServerToolCallArguments(doc.RootElement.Deserialize<ServerToolCallPart>(options)),
231MessagePart.ServerToolCallResponseType => doc.RootElement.Deserialize<ServerToolCallResponsePart>(options),
232_ => doc.RootElement.Deserialize<GenericPart>(options),
242errorPart = doc.RootElement.Deserialize<UnexpectedErrorPart>(options);
Aspire.Dashboard.Tests (14)
Aspire.Hosting (6)
Aspire.Hosting.Azure (1)
Aspire.Hosting.Azure.Tests (5)
Aspire.Hosting.Blazor (1)
Aspire.Hosting.Browsers (2)
Aspire.Hosting.Browsers.Tests (26)
BrowserLogsBuilderExtensionsTests.cs (20)
804Assert.Equal("web-browser-logs", document.RootElement.GetProperty("resourceName").GetString());
805Assert.Equal("session-0002", document.RootElement.GetProperty("sessionId").GetString());
806Assert.Equal("msedge", document.RootElement.GetProperty("browser").GetString());
807Assert.Equal(@"C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe", document.RootElement.GetProperty("browserExecutable").GetString());
808Assert.Equal("Adopted", document.RootElement.GetProperty("browserHostOwnership").GetString());
809Assert.Equal(4242, document.RootElement.GetProperty("processId").GetInt32());
810Assert.Equal("target-0002", document.RootElement.GetProperty("targetId").GetString());
811Assert.Equal("https://localhost:8443/", document.RootElement.GetProperty("targetUrl").GetString());
812Assert.EndsWith("screenshot.png", document.RootElement.GetProperty("path").GetString(), StringComparison.Ordinal);
813Assert.Equal("image/png", document.RootElement.GetProperty("mimeType").GetString());
814Assert.Equal(1234, document.RootElement.GetProperty("sizeBytes").GetInt32());
893var path = document.RootElement.GetProperty("path").GetString();
898Assert.Equal("session-0001", document.RootElement.GetProperty("sessionId").GetString());
899Assert.Equal("chrome", document.RootElement.GetProperty("browser").GetString());
900Assert.Equal("/fake/browser-1", document.RootElement.GetProperty("browserExecutable").GetString());
901Assert.Equal("Owned", document.RootElement.GetProperty("browserHostOwnership").GetString());
902Assert.Equal(1001, document.RootElement.GetProperty("processId").GetInt32());
903Assert.Equal("target-1", document.RootElement.GetProperty("targetId").GetString());
904Assert.Equal("http://localhost:8080/", document.RootElement.GetProperty("targetUrl").GetString());
905Assert.Equal(session.ScreenshotBytes.Length, document.RootElement.GetProperty("sizeBytes").GetInt32());
Aspire.Hosting.CodeGeneration.TypeScript (1)
Aspire.Hosting.CodeGeneration.TypeScript.Tests (2)
Aspire.Hosting.DevTunnels (1)
Aspire.Hosting.EntityFrameworkCore (2)
Aspire.Hosting.Java.Tests (1)
Aspire.Hosting.JavaScript (1)
Aspire.Hosting.Kubernetes (6)
Aspire.Hosting.Maui (1)
Aspire.Hosting.OpenAI (1)
Aspire.Hosting.PostgreSQL.Tests (1)
Aspire.Hosting.Radius (4)
Aspire.Hosting.Radius.Tests (1)
Aspire.Hosting.RemoteHost (2)
Aspire.Hosting.RemoteHost.Tests (5)
Aspire.Hosting.Rust (1)
Aspire.Hosting.Sdk.Tests (1)
Aspire.Hosting.Seq.Tests (1)
Aspire.Hosting.Tests (31)
Aspire.Templates.Tests (1)
Aspire.TestTools (5)
dotnet (5)
dotnet-aot (4)
dotnet-openapi (1)
dotnet-sourcelink (1)
dotnet-user-jwts (2)
ILCompiler.Compiler (1)
ILCompiler.ReadyToRun (1)
Infrastructure.Tests (21)
Microsoft.AspNetCore.Authentication.Facebook (1)
Microsoft.AspNetCore.Authentication.Google (1)
Microsoft.AspNetCore.Authentication.MicrosoftAccount (1)
Microsoft.AspNetCore.Authentication.OAuth (3)
Microsoft.AspNetCore.Authentication.OpenIdConnect (2)
Microsoft.AspNetCore.Authentication.Twitter (1)
Microsoft.AspNetCore.Components.WebAssembly.Server (1)
Microsoft.AspNetCore.Grpc.JsonTranscoding (3)
Microsoft.AspNetCore.JsonPatch.SystemTextJson (2)
Microsoft.AspNetCore.Mvc.ViewFeatures (1)
Microsoft.Build (1)
Microsoft.CodeAnalysis.Features (1)
Microsoft.CodeAnalysis.Workspaces.MSBuild (1)
Microsoft.Deployment.DotNet.Releases (2)
Microsoft.DotNet.Arcade.Sdk (1)
Microsoft.DotNet.ProjectTools (1)
Microsoft.Extensions.AI (1)
Microsoft.Extensions.AI.Abstractions.Tests (29)
Microsoft.Extensions.AI.Evaluation.Reporting.Tests (2)
Microsoft.Extensions.AI.Evaluation.Safety (5)
Microsoft.Extensions.AI.OpenAI (3)
Microsoft.Extensions.AI.OpenAI.Tests (10)
Microsoft.Extensions.AI.Tests (9)
Microsoft.Extensions.Configuration.Json (3)
Microsoft.ML.Tokenizers (1)
Microsoft.ML.Tokenizers.Tests (2)
Microsoft.NET.Build.Containers (8)
Microsoft.NET.HostModel (1)
Microsoft.SourceLink.Tools.Package (1)
Microsoft.TemplateEngine.Edge (2)
Microsoft.TemplateEngine.Orchestrator.RunnableProjects (2)
Microsoft.TemplateEngine.Utils (2)
Microsoft.TemplateSearch.Common (2)
Microsoft.TestPlatform.CommunicationUtilities (21)
Microsoft.TestPlatform.TestHostRuntimeProvider (1)
NuGet.Protocol (3)
RepoTasks (2)
rzc (1)
Shared.Tests (2)
System.Text.Json (15)