MCPcopy
hub / github.com/urfave/cli / TestMapValueSourceStringer

Function TestMapValueSourceStringer

value_source_test.go:338–348  ·  value_source_test.go::TestMapValueSourceStringer
(t *testing.T)

Source from the content-addressed store, hash-verified

336}
337
338func TestMapValueSourceStringer(t *testing.T) {
339 m := map[any]any{
340 "foo": map[any]any{
341 "bar": 10,
342 },
343 }
344 mvs := NewMapValueSource("bar", NewMapSource("test", m))
345
346 assert.Equal(t, `&mapValueSource{key:"bar", src:&mapSource{name:"test"}}`, mvs.GoString())
347 assert.Equal(t, `key "bar" from map source "test"`, mvs.String())
348}

Callers

nothing calls this directly

Calls 4

NewMapValueSourceFunction · 0.85
NewMapSourceFunction · 0.85
GoStringMethod · 0.45
StringMethod · 0.45

Tested by

no test coverage detected