feat: Add confirm prompts to some cli actions (#1591)

* feat: Add confirm prompts to some cli actions
- Add optional -y skip. Standardize -y flag across commands
This commit is contained in:
Steven Masley
2022-05-20 10:59:04 -05:00
committed by GitHub
parent 4f70f84635
commit ad946c3902
10 changed files with 121 additions and 39 deletions

View File

@ -20,7 +20,7 @@ func TestDelete(t *testing.T) {
template := coderdtest.CreateTemplate(t, client, user.OrganizationID, version.ID)
workspace := coderdtest.CreateWorkspace(t, client, user.OrganizationID, template.ID)
coderdtest.AwaitWorkspaceBuildJob(t, client, workspace.LatestBuild.ID)
cmd, root := clitest.New(t, "delete", workspace.Name)
cmd, root := clitest.New(t, "delete", workspace.Name, "-y")
clitest.SetupConfig(t, client, root)
doneChan := make(chan struct{})
pty := ptytest.New(t)