29 writes to State
Aspire.Cli.Tests (29)
Backchannel\ResourceSnapshotMapperTests.cs (19)
85
State
= "Enabled",
111
new ResourceSnapshotCommand { Name = "start",
State
= "Disabled", Description = "Start" },
112
new ResourceSnapshotCommand { Name = "save",
State
= "Hidden", Description = "Save parameter" },
113
new ResourceSnapshotCommand { Name = "dashboard-only",
State
= "Enabled", Description = "UI only", Visibility = KnownCommandVisibility.UI },
114
new ResourceSnapshotCommand { Name = "missing-visibility",
State
= "Enabled", Description = "Missing visibility", Visibility = null! }
174
new ResourceSnapshotCommand { Name = "restart",
State
= KnownCommandState.Enabled, Description = "Restart" },
175
new ResourceSnapshotCommand { Name = "start",
State
= KnownCommandState.Disabled, Description = "Start" },
176
new ResourceSnapshotCommand { Name = "save",
State
= KnownCommandState.Hidden, Description = "Save parameter" }
198
new ResourceSnapshotCommand { Name = "api-only",
State
= KnownCommandState.Enabled, Description = "API only", Visibility = KnownCommandVisibility.Api },
199
new ResourceSnapshotCommand { Name = "ui-only",
State
= KnownCommandState.Enabled, Description = "UI only", Visibility = KnownCommandVisibility.UI },
200
new ResourceSnapshotCommand { Name = "ui-disabled",
State
= KnownCommandState.Disabled, Description = "UI disabled", Visibility = KnownCommandVisibility.UI }
224
new ResourceSnapshotCommand { Name = "set-parameter",
State
= KnownCommandState.Enabled, Description = "Set", Visibility = KnownCommandVisibility.Api },
225
new ResourceSnapshotCommand { Name = "custom-action",
State
= KnownCommandState.Enabled, Description = "Custom", Visibility = KnownCommandVisibility.Api },
226
new ResourceSnapshotCommand { Name = "delete-parameter",
State
= KnownCommandState.Enabled, Description = "Delete", Visibility = KnownCommandVisibility.Api }
252
new ResourceSnapshotCommand { Name = "set-parameter",
State
= KnownCommandState.Enabled, Description = "Set", Visibility = KnownCommandVisibility.Api },
253
new ResourceSnapshotCommand { Name = "custom-action",
State
= KnownCommandState.Enabled, Description = "Custom", Visibility = KnownCommandVisibility.Api },
254
new ResourceSnapshotCommand { Name = "delete-parameter",
State
= KnownCommandState.Enabled, Description = "Delete", Visibility = KnownCommandVisibility.Api }
282
State
= KnownCommandState.Enabled,
325
State
= "Enabled",
Commands\DescribeCommandTests.cs (2)
593
State
= KnownCommandState.Enabled,
600
State
= KnownCommandState.Disabled,
Commands\ResourceCommandTests.cs (1)
2395
State
= state,
Mcp\ListResourcesToolTests.cs (7)
514
State
= "Enabled",
554
new ResourceSnapshotCommand { Name = "disabled",
State
= "disabled", Visibility = "api" },
555
new ResourceSnapshotCommand { Name = "hidden",
State
= "Hidden" },
556
new ResourceSnapshotCommand { Name = "ui-only",
State
= "Enabled", Visibility = "UI" },
557
new ResourceSnapshotCommand { Name = "none",
State
= "Enabled", Visibility = "None" }
575
State
= "Enabled",
950
State
= "Enabled",
5 references to State
aspire (5)
Backchannel\ResourceSnapshotMapper.cs (3)
117
.Where(c => IsCommandVisibleForConsumer(c.command.Visibility, includeDisabledCommands) && IsCommandVisibleToConsumer(c.command.
State
, includeDisabledCommands))
126
State = c.command.
State
,
228
return string.Equals(command.
State
, "Enabled", StringComparison.OrdinalIgnoreCase) &&
Mcp\Tools\ListResourcesTool.cs (2)
307
ResourceSnapshotMapper.IsCommandVisibleToConsumer(command.
State
, includeDisabledCommands: true))
313
State = string.Equals(command.
State
, KnownCommandState.Enabled, StringComparison.OrdinalIgnoreCase)