MCPcopy
hub / github.com/mislav/hub / TestArgs_GlobalFlags_Repeated

Function TestArgs_GlobalFlags_Repeated

commands/args_test.go:101–107  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

99}
100
101func TestArgs_GlobalFlags_Repeated(t *testing.T) {
102 args := NewArgs([]string{"-C", "mydir", "-c", "a=b", "--bare", "-c", "c=d", "-c", "e=f", "status"})
103 assert.Equal(t, "status", args.Command)
104 assert.Equal(t, []string{"-C", "mydir", "-c", "a=b", "--bare", "-c", "c=d", "-c", "e=f"}, args.GlobalFlags)
105 assert.Equal(t, 0, len(args.Params))
106 assert.Equal(t, false, args.Noop)
107}
108
109func TestArgs_GlobalFlags_Propagate(t *testing.T) {
110 args := NewArgs([]string{"-c", "key=value", "status"})

Callers

nothing calls this directly

Calls 1

NewArgsFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…