19 references to StopCommand
Aspire.Dashboard (4)
Components\Layout\ResourcesLayout.razor.cs (2)
1880
KnownResourceState.Running => [CommandViewModel.
StopCommand
, CommandViewModel.RestartCommand],
1898
c.Name is not (CommandViewModel.StartCommand or CommandViewModel.
StopCommand
or CommandViewModel.RestartCommand))
Model\DashboardCommandExecutor.cs (1)
54
if (dashboardClient.IsReadOnly || commandName is not (CommandViewModel.
StopCommand
or CommandViewModel.StartCommand))
Model\ResourceViewModel.cs (1)
313
private static readonly string[] s_knownResourceCommands = [StartCommand,
StopCommand
, RestartCommand, RebuildCommand, SetParameterCommand, DeleteParameterCommand];
Aspire.Dashboard.Components.Tests (4)
Layout\ResourcesLayoutTests.cs (4)
1617
new(CommandViewModel.
StopCommand
, state, "Stop", "", confirmationMessage: "", argumentInputs: [], isHighlighted: true, iconName: "", iconVariant: IconVariant.Regular);
1752
Command(CommandViewModel.
StopCommand
, CommandViewModelState.Enabled, true),
1790
Command(CommandViewModel.
StopCommand
, CommandViewModelState.Enabled, false),
1895
Command(CommandViewModel.
StopCommand
, CommandViewModelState.Enabled),
Aspire.Dashboard.Tests (11)
Model\DashboardCommandExecutorTests.cs (10)
45
[InlineData(CommandViewModel.
StopCommand
, true)]
73
var resource = ModelTestHelpers.CreateResource(resourceName: "api", commands: [CreateCommand(CommandViewModel.
StopCommand
)]);
75
Assert.False(await executor.ExecuteGraphGameCommandAsync(resource, CommandViewModel.
StopCommand
, r => r.DisplayName));
84
var resource = ModelTestHelpers.CreateResource(resourceName: "api", commands: [CreateCommand(CommandViewModel.
StopCommand
)]);
86
Assert.False(await executor.ExecuteGraphGameCommandAsync(resource, CommandViewModel.
StopCommand
, r => r.DisplayName));
103
var resource = ModelTestHelpers.CreateResource(resourceName: "api", commands: [CreateCommand(CommandViewModel.
StopCommand
, state, confirmationMessage)]);
105
Assert.Null(await executor.ExecuteGraphGameCommandAsync(resource, CommandViewModel.
StopCommand
, r => r.DisplayName));
123
var resource = ModelTestHelpers.CreateResource(resourceName: "api", commands: [CreateCommand(CommandViewModel.
StopCommand
)]);
125
Assert.Null(await executor.ExecuteGraphGameCommandAsync(resource, CommandViewModel.
StopCommand
, r => r.DisplayName));
136
Assert.Null(await executor.ExecuteGraphGameCommandAsync(resource, CommandViewModel.
StopCommand
, r => r.DisplayName));
Model\ResourceMenuBuilderTests.cs (1)
420
CommandViewModel.
StopCommand
,