5 writes to AppHosts
aspire (1)
Backchannel\TrayWatchStream.cs (1)
291AppHosts = hosts.Select((host, index) => host with { Health = healthSubscriptions[candidates[index].Connection].Health })
Aspire.Cli.Tests (4)
Backchannel\TrayWatchStreamTests.cs (4)
1042AppHosts = [host] 1047JsonSerializer.Serialize(snapshot with { AppHosts = [host with { Health = "healthy" }] }, TrayCliJsonContext.Default.TrayWatchMessage), 1048JsonSerializer.Serialize(snapshot with { AppHosts = [host with { Health = "warning" }] }, TrayCliJsonContext.Default.TrayWatchMessage), 1049JsonSerializer.Serialize(snapshot with { AppHosts = [host with { Health = "unhealthy" }] }, TrayCliJsonContext.Default.TrayWatchMessage),
28 references to AppHosts
Aspire.Cli.Tests (28)
Backchannel\TrayWatchStreamTests.cs (27)
45Assert.Empty(message.AppHosts!); 144Assert.Collection(message.AppHosts!, 148message => Assert.Equal(20, Assert.Single(message.AppHosts!).AppHostPid), 149message => Assert.Empty(message.AppHosts!)); 177Assert.Null(error.AppHosts); 180Assert.Single(messages[0].AppHosts!); 227Assert.Null(error.AppHosts); 241received.Add(Assert.Single(Deserialize(json).AppHosts!).AppHostPid); 417Assert.Collection(snapshot.AppHosts!, 467Assert.Null(Assert.Single(initial.AppHosts!).DashboardUrl); 472var host = Assert.Single(retried.AppHosts!); 602Assert.Equal(Enumerable.Range(1, TrayCliProtocol.MaximumAppHosts), snapshot.AppHosts!.Select(host => host.AppHostPid)); 603Assert.All(snapshot.AppHosts!, host => Assert.Null(host.DashboardUrl)); 651Assert.Equal(blockedCount, initial.AppHosts!.Count); 652Assert.All(initial.AppHosts, host => Assert.Null(host.DashboardUrl)); 673var host = Assert.Single(snapshot.AppHosts!); 679Assert.Collection(snapshot.AppHosts!, 714Assert.Null(Assert.Single(snapshot.AppHosts!).DashboardUrl); 794return Assert.Single(message.AppHosts!); 838Assert.Equal("healthy", Assert.Single((await messages.Reader.ReadAsync().AsTask().DefaultTimeout()).AppHosts!).Health); 843Assert.Null(Assert.Single(message.AppHosts!).Health); 881var first = Assert.Single((await messages.Reader.ReadAsync().AsTask().DefaultTimeout()).AppHosts!); 886Assert.Empty((await messages.Reader.ReadAsync().AsTask().DefaultTimeout()).AppHosts!); 891var second = Assert.Single((await messages.Reader.ReadAsync().AsTask().DefaultTimeout()).AppHosts!); 957Assert.Equal("healthy", Assert.Single((await messages.Reader.ReadAsync().DefaultTimeout()).AppHosts!).Health); 961Assert.Empty((await messages.Reader.ReadAsync().DefaultTimeout()).AppHosts!); 964var host = Assert.Single((await messages.Reader.ReadAsync().DefaultTimeout()).AppHosts!);
Commands\TrayProtocolCommandTests.cs (1)
45Assert.Empty(message.AppHosts!);