Skip to content

Commit 3658639

Browse files
author
Ian Campbell
committed
e2e: do not use --tls argument in TestDialStdio
If the environment is not setup for tls (i.e. `$HOME/.docker/ca.pem` doesn't exist) then this will exit with an error instead of allowing the test to complete. Since we just wanted to test that the `dial-stdio` was called with the same set of options as the initial invocation just drop it, the other args already in place serve the purpose well enough. Signed-off-by: Ian Campbell <ijc@docker.com>
1 parent 556d7e9 commit 3658639

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

e2e/cli-plugins/dial_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ func TestDialStdio(t *testing.T) {
1818
// follows. We observe this from the debug level logging from
1919
// the connhelper stuff.
2020
helloworld := filepath.Join(os.Getenv("DOCKER_CLI_E2E_PLUGINS_EXTRA_DIRS"), "docker-helloworld")
21-
cmd := icmd.Command(helloworld, "--config=blah", "--tls", "--log-level", "debug", "helloworld", "--who=foo")
21+
cmd := icmd.Command(helloworld, "--config=blah", "--log-level", "debug", "helloworld", "--who=foo")
2222
res := icmd.RunCmd(cmd, icmd.WithEnv(manager.ReexecEnvvar+"=/bin/true"))
2323
res.Assert(t, icmd.Success)
24-
assert.Assert(t, is.Contains(res.Stderr(), `msg="commandconn: starting /bin/true with [--config=blah --tls --log-level debug system dial-stdio]"`))
24+
assert.Assert(t, is.Contains(res.Stderr(), `msg="commandconn: starting /bin/true with [--config=blah --log-level debug system dial-stdio]"`))
2525
assert.Assert(t, is.Equal(res.Stdout(), "Hello foo!\n"))
2626
}

0 commit comments

Comments
 (0)