MCPcopy
hub / github.com/docker/docker-agent / Close

Method Close

pkg/tools/lifecycle/supervisor_test.go:58–71  ·  view source on GitHub ↗
(context.Context)

Source from the content-addressed store, hash-verified

56}
57
58func (f *fakeSession) Close(context.Context) error {
59 f.mu.Lock()
60 defer f.mu.Unlock()
61 if !f.closed {
62 f.closed = true
63 close(f.closedCh)
64 // Closed sessions return nil from Wait by convention.
65 select {
66 case f.failCh <- nil:
67 default:
68 }
69 }
70 return nil
71}
72
73// waitClosed blocks until Close has been called on the session.
74func (f *fakeSession) waitClosed(t *testing.T) {

Callers

nothing calls this directly

Calls 2

LockMethod · 0.45
UnlockMethod · 0.45

Tested by

no test coverage detected