17 references to KnownCommandState
aspire (2)
Backchannel\ResourceSnapshotMapper.cs (2)
250return string.Equals(state, KnownCommandState.Enabled, StringComparison.OrdinalIgnoreCase) 251|| (includeDisabledCommands && string.Equals(state, KnownCommandState.Disabled, StringComparison.OrdinalIgnoreCase));
Aspire.Cli.Tests (15)
Backchannel\ResourceSnapshotMapperTests.cs (15)
141new ResourceSnapshotCommand { Name = "restart", State = KnownCommandState.Enabled, Description = "Restart" }, 142new ResourceSnapshotCommand { Name = "start", State = KnownCommandState.Disabled, Description = "Start" }, 143new ResourceSnapshotCommand { Name = "save", State = KnownCommandState.Hidden, Description = "Save parameter" } 150Assert.Equal(KnownCommandState.Enabled, result.Commands["restart"].State); 151Assert.Equal(KnownCommandState.Disabled, result.Commands["start"].State); 165new ResourceSnapshotCommand { Name = "api-only", State = KnownCommandState.Enabled, Description = "API only", Visibility = KnownCommandVisibility.Api }, 166new ResourceSnapshotCommand { Name = "ui-only", State = KnownCommandState.Enabled, Description = "UI only", Visibility = KnownCommandVisibility.UI }, 167new ResourceSnapshotCommand { Name = "ui-disabled", State = KnownCommandState.Disabled, Description = "UI disabled", Visibility = KnownCommandVisibility.UI } 191new ResourceSnapshotCommand { Name = "set-parameter", State = KnownCommandState.Enabled, Description = "Set", Visibility = KnownCommandVisibility.Api }, 192new ResourceSnapshotCommand { Name = "custom-action", State = KnownCommandState.Enabled, Description = "Custom", Visibility = KnownCommandVisibility.Api }, 193new ResourceSnapshotCommand { Name = "delete-parameter", State = KnownCommandState.Enabled, Description = "Delete", Visibility = KnownCommandVisibility.Api } 219new ResourceSnapshotCommand { Name = "set-parameter", State = KnownCommandState.Enabled, Description = "Set", Visibility = KnownCommandVisibility.Api }, 220new ResourceSnapshotCommand { Name = "custom-action", State = KnownCommandState.Enabled, Description = "Custom", Visibility = KnownCommandVisibility.Api }, 221new ResourceSnapshotCommand { Name = "delete-parameter", State = KnownCommandState.Enabled, Description = "Delete", Visibility = KnownCommandVisibility.Api } 249State = KnownCommandState.Enabled,