MCPcopy Index your code
hub / github.com/docker/cli / TestRunNonexisting

Function TestRunNonexisting

e2e/cli-plugins/run_test.go:14–24  ·  view source on GitHub ↗

TestRunNonexisting ensures correct behaviour when running a nonexistent plugin.

(t *testing.T)

Source from the content-addressed store, hash-verified

12
13// TestRunNonexisting ensures correct behaviour when running a nonexistent plugin.
14func TestRunNonexisting(t *testing.T) {
15 run, _, cleanup := prepare(t)
16 defer cleanup()
17
18 res := icmd.RunCmd(run("nonexistent"))
19 res.Assert(t, icmd.Expected{
20 ExitCode: 1,
21 Out: icmd.None,
22 })
23 golden.Assert(t, res.Stderr(), "docker-nonexistent-err.golden")
24}
25
26// TestHelpNonexisting ensures correct behaviour when invoking help on a nonexistent plugin.
27func TestHelpNonexisting(t *testing.T) {

Callers

nothing calls this directly

Calls 2

prepareFunction · 0.85
runFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…