MCPcopy Create free account
hub / github.com/docker/docker-agent / TestMultiProviderTryInOrder

Function TestMultiProviderTryInOrder

pkg/environment/multi_test.go:28–35  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

26}
27
28func TestMultiProviderTryInOrder(t *testing.T) {
29 t.Parallel()
30 provider := NewMultiProvider(&neverFound{}, &alwaysFound{})
31 value, found := provider.Get(t.Context(), "TEST3")
32
33 assert.Equal(t, "FOUND", value)
34 assert.True(t, found)
35}
36
37func TestMultiProviderEmptyValue(t *testing.T) {
38 t.Parallel()

Callers

nothing calls this directly

Calls 3

GetMethod · 0.95
NewMultiProviderFunction · 0.85
ContextMethod · 0.80

Tested by

no test coverage detected