MCPcopy Index your code
hub / github.com/docker-exec/dexec / TestImage

Function TestImage

cli/cli_test.go:199–215  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

197}
198
199func TestImage(t *testing.T) {
200 cases := []struct {
201 osArgs []string
202 want []string
203 }{
204 {
205 []string{"filename", "-m", "foo", "--image", "bar", "--image=foobar"},
206 []string{"foo", "bar", "foobar"},
207 },
208 }
209 for _, c := range cases {
210 got := ParseOsArgs(c.osArgs)
211 if !reflect.DeepEqual(got.Options[Image], c.want) {
212 t.Errorf("ParseOsArgs %q != %q", got.Options[Image], c.want)
213 }
214 }
215}
216
217func TestExtension(t *testing.T) {
218 cases := []struct {

Callers

nothing calls this directly

Calls 1

ParseOsArgsFunction · 0.85

Tested by

no test coverage detected