MCPcopy Create free account
hub / github.com/docker/cli / TestInvokeAndCollectHooksNoPlugins

Function TestInvokeAndCollectHooksNoPlugins

cli-plugins/manager/hooks_test.go:345–356  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

343}
344
345func TestInvokeAndCollectHooksNoPlugins(t *testing.T) {
346 cfg := configfile.New("")
347 root := &cobra.Command{Use: "docker"}
348 sub := &cobra.Command{Use: "build"}
349 root.AddCommand(sub)
350
351 result := invokeAndCollectHooks(
352 context.Background(), cfg, root, sub,
353 "build", map[string]string{}, "some error",
354 )
355 assert.Check(t, is.Len(result, 0))
356}
357
358func TestInvokeAndCollectHooksCancelledContext(t *testing.T) {
359 cfg := configfile.New("")

Callers

nothing calls this directly

Calls 2

invokeAndCollectHooksFunction · 0.85
LenMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…