(t *testing.T)
| 16 | ) |
| 17 | |
| 18 | func TestConnectExists_Running(t *testing.T) { |
| 19 | t.Parallel() |
| 20 | ctx := testutil.Context(t, testutil.WaitShort) |
| 21 | |
| 22 | var root cli.RootCmd |
| 23 | cmd, err := root.Command(root.AGPL()) |
| 24 | require.NoError(t, err) |
| 25 | |
| 26 | inv := (&serpent.Invocation{ |
| 27 | Command: cmd, |
| 28 | Args: []string{"connect", "exists", "test.example"}, |
| 29 | }).WithContext(withCoderConnectRunning(ctx)) |
| 30 | stdout := new(bytes.Buffer) |
| 31 | stderr := new(bytes.Buffer) |
| 32 | inv.Stdout = stdout |
| 33 | inv.Stderr = stderr |
| 34 | err = inv.Run() |
| 35 | require.NoError(t, err) |
| 36 | } |
| 37 | |
| 38 | func TestConnectExists_NotRunning(t *testing.T) { |
| 39 | t.Parallel() |
nothing calls this directly
no test coverage detected