3 writes to Commands
Aspire.Hosting (1)
ApplicationModel\ResourceNotificationService.cs (1)
1138return previousState with { Commands = builder.ToImmutable() };
Aspire.Hosting.Tests (2)
Backchannel\AuxiliaryBackchannelRpcTargetTests.cs (1)
207Commands = [
ResourceNotificationTests.cs (1)
1512Commands = [CreateTestCommand(commandArguments)],
31 references to Commands
Aspire.Hosting (10)
ApplicationModel\CustomResourceSnapshot.cs (2)
202Commands.SequenceEqual(other.Commands) &&
ApplicationModel\ResourceNotificationService.cs (6)
939string.Join(" ", newState.Commands.Select(c => $"{c.Name} ({c.DisplayName}) = {Stringify(c.State)}"))); 1096var existingCommand = FindByName(previousState.Commands, annotation.Name); 1102builder = ImmutableArray.CreateBuilder<ResourceCommandSnapshot>(previousState.Commands.Length); 1103builder.AddRange(previousState.Commands); 1118builder = ImmutableArray.CreateBuilder<ResourceCommandSnapshot>(previousState.Commands.Length); 1119builder.AddRange(previousState.Commands);
Backchannel\AuxiliaryBackchannelRpcTarget.cs (1)
1172var commands = snapshot.Commands
Dashboard\DashboardServiceData.cs (1)
86Commands = snapshot.Commands,
Aspire.Hosting.Azure.Tests (9)
AzureEnvironmentResourceExtensionsTests.cs (9)
382Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Enabled, command.State)); 1669var cancelCommand = Assert.Single(storageEvent.Snapshot.Commands, c => c.Name == AzureProvisioningController.CancelCommandName); 1972Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Disabled, command.State)); 2247Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Disabled, command.State)); 2261Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Enabled, command.State)); 2307Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Disabled, command.State)); 2319Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Enabled, command.State)); 2727Assert.All(environmentEvent.Snapshot.Commands, command => Assert.Equal(ResourceCommandState.Disabled, command.State)); 5054var command = Assert.Single(snapshot.Commands, c => c.Name == commandName);
Aspire.Hosting.Browsers.Tests (4)
BrowserLogsBuilderExtensionsTests.cs (4)
1347resourceEvent => resourceEvent.Snapshot.Commands.Any(command => 1351Assert.Equal(ResourceCommandState.Disabled, initialEvent.Snapshot.Commands.Single(command => command.Name == BrowserLogsBuilderExtensions.OpenTrackedBrowserCommandName).State); 1363resourceEvent => resourceEvent.Snapshot.Commands.Any(command => 1367Assert.Equal(ResourceCommandState.Enabled, enabledEvent.Snapshot.Commands.Single(command => command.Name == BrowserLogsBuilderExtensions.OpenTrackedBrowserCommandName).State);
Aspire.Hosting.Tests (8)
WithHttpCommandTests.cs (8)
959Assert.Equal(ResourceCommandState.Disabled, startingEvent.Snapshot.Commands.First(c => c.Name == "mycommand").State); 971e.Snapshot.Commands.First(c => c.Name == "mycommand").State == ResourceCommandState.Enabled).DefaultTimeout(); 973Assert.Equal(ResourceCommandState.Enabled, runningEvent.Snapshot.Commands.First(c => c.Name == "mycommand").State); 1014e.Snapshot.Commands.First(c => c.Name == "mycommand").State == ResourceCommandState.Hidden).DefaultTimeout(); 1016Assert.Equal(ResourceCommandState.Hidden, runningEvent.Snapshot.Commands.First(c => c.Name == "mycommand").State); 1028e => e.Snapshot.Commands.First(c => c.Name == "mycommand").State == ResourceCommandState.Enabled).DefaultTimeout(); 1031Assert.Equal(ResourceCommandState.Enabled, enabledEvent.Snapshot.Commands.First(c => c.Name == "mycommand").State); 1070e.Snapshot.Commands.FirstOrDefault(c => c.Name == commandName)?.State == ResourceCommandState.Enabled).DefaultTimeout();