MCPcopy Index your code
hub / github.com/docker/docker-agent / TestLocalRuntime_Contract

Function TestLocalRuntime_Contract

pkg/runtime/contract_test.go:131–144  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

129}
130
131func TestLocalRuntime_Contract(t *testing.T) {
132 t.Parallel()
133
134 runRuntimeContract(t, func(t *testing.T) Runtime {
135 t.Helper()
136 prov := &mockProvider{id: "test/mock-model", stream: &mockStream{}}
137 root := agent.New("root", "You are a test agent", agent.WithModel(prov))
138 tm := team.New(team.WithAgents(root))
139
140 rt, err := New(t.Context(), tm, WithSessionCompaction(false), WithModelStore(mockModelStore{}))
141 require.NoError(t, err)
142 return rt
143 })
144}

Callers

nothing calls this directly

Calls 9

NewFunction · 0.92
WithModelFunction · 0.92
NewFunction · 0.92
WithAgentsFunction · 0.92
runRuntimeContractFunction · 0.85
WithSessionCompactionFunction · 0.85
WithModelStoreFunction · 0.85
ContextMethod · 0.80
NewFunction · 0.70

Tested by

no test coverage detected