54 references to LogTestHelpers
Aspire.Dashboard.Tests (54)
Integration\FrontendBrowserTokenAuthTests.cs (15)
376Assert.Equal("Aspire dashboard version: {Version}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 380Assert.Equal("Now listening on: {DashboardUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 382var uri = new Uri((string)LogTestHelpers.GetValue(w, "DashboardUri")!); 387Assert.Equal("OTLP/gRPC listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 389var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 394Assert.Equal("OTLP/HTTP listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 396var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 401Assert.Equal("OTLP server is unsecured. Untrusted apps can send telemetry to the dashboard. For more information, visit https://go.microsoft.com/fwlink/?linkid=2267030", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 406Assert.Equal("Dashboard API is unsecured. Untrusted apps can access sensitive telemetry data.", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 411Assert.Equal("Login to the dashboard at {LoginUrl}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 413var loginUrl = (string)LogTestHelpers.GetValue(w, "LoginUrl")!; 420Assert.StartsWith("Aspire Dashboard", (string)LogTestHelpers.GetValue(w, "{OriginalFormat}")!); 422var loginUrl = (string)LogTestHelpers.GetValue(w, "LoginUrl")!; 451var summaryLog = l.Single(w => ((string?)LogTestHelpers.GetValue(w, "{OriginalFormat}"))?.StartsWith("Aspire Dashboard") == true); 453var loginUrl = (string)LogTestHelpers.GetValue(summaryLog, "LoginUrl")!;
Integration\StartupTests.cs (26)
690Assert.Equal("Aspire dashboard version: {Version}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 694Assert.Equal("Now listening on: {DashboardUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 696var uri = new Uri((string)LogTestHelpers.GetValue(w, "DashboardUri")!); 701Assert.Equal("OTLP/gRPC listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 703var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 708Assert.Equal("OTLP/HTTP listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 710var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 715Assert.Equal("OTLP server is unsecured. Untrusted apps can send telemetry to the dashboard. For more information, visit https://go.microsoft.com/fwlink/?linkid=2267030", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 720Assert.Equal("Dashboard API is unsecured. Untrusted apps can access sensitive telemetry data.", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 725Assert.StartsWith("Aspire Dashboard", (string)LogTestHelpers.GetValue(w, "{OriginalFormat}")!); 752Assert.Equal("Aspire dashboard version: {Version}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 756Assert.Equal("Now listening on: {DashboardUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 760Assert.Equal("Dashboard API is unsecured. Untrusted apps can access sensitive telemetry data.", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 765Assert.StartsWith("Aspire Dashboard", (string)LogTestHelpers.GetValue(w, "{OriginalFormat}")!); 811Assert.Contains(warnings, w => LogTestHelpers.GetValue(w, "{OriginalFormat}")?.ToString() == ApiUnsecuredWarning); 815Assert.DoesNotContain(warnings, w => LogTestHelpers.GetValue(w, "{OriginalFormat}")?.ToString() == ApiUnsecuredWarning); 872Assert.Equal("Aspire dashboard version: {Version}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 876Assert.Equal("Now listening on: {DashboardUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 878var uri = new Uri((string)LogTestHelpers.GetValue(w, "DashboardUri")!); 885Assert.Equal("OTLP/gRPC listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 887var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 892Assert.Equal("OTLP/HTTP listening on: {OtlpEndpointUri}", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 894var uri = new Uri((string)LogTestHelpers.GetValue(w, "OtlpEndpointUri")!); 899Assert.Equal("OTLP server is unsecured. Untrusted apps can send telemetry to the dashboard. For more information, visit https://go.microsoft.com/fwlink/?linkid=2267030", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 904Assert.Equal("Dashboard API is unsecured. Untrusted apps can access sensitive telemetry data.", LogTestHelpers.GetValue(w, "{OriginalFormat}")); 909Assert.StartsWith("Aspire Dashboard", (string)LogTestHelpers.GetValue(w, "{OriginalFormat}")!);
LoggingHelpersTests.cs (13)
31Assert.Equal("Login to the dashboard at {LoginUrl}", LogTestHelpers.GetValue(loginWrite, "{OriginalFormat}")); 32Assert.Equal("http://localhost:18888/login?t=abc123", LogTestHelpers.GetValue(loginWrite, "LoginUrl")); 48Assert.Equal("http://localhost:18888", LogTestHelpers.GetValue(write, "DashboardUrl")); 49Assert.Equal("http://localhost:18889", LogTestHelpers.GetValue(write, "OtlpGrpcUrl")); 50Assert.Equal("http://localhost:18890", LogTestHelpers.GetValue(write, "OtlpHttpUrl")); 51Assert.Equal("http://localhost:18888/login?t=abc123", LogTestHelpers.GetValue(write, "LoginUrl")); 80Assert.Null(LogTestHelpers.GetValue(write, "LoginUrl")); 129Assert.Null(LogTestHelpers.GetValue(write, "DashboardUrl")); 130Assert.Null(LogTestHelpers.GetValue(write, "LoginUrl")); 131Assert.Equal("http://localhost:18889", LogTestHelpers.GetValue(write, "OtlpGrpcUrl")); 132Assert.Equal("http://localhost:18890", LogTestHelpers.GetValue(write, "OtlpHttpUrl")); 193Assert.Null(LogTestHelpers.GetValue(write, "OtlpGrpcUrl")); 194Assert.Null(LogTestHelpers.GetValue(write, "OtlpHttpUrl"));