MCPcopy
hub / github.com/nats-io/nats.go / WaitTime

Function WaitTime

nats_test.go:55–62  ·  view source on GitHub ↗
(ch chan bool, timeout time.Duration)

Source from the content-addressed store, hash-verified

53}
54
55func WaitTime(ch chan bool, timeout time.Duration) error {
56 select {
57 case <-ch:
58 return nil
59 case <-time.After(timeout):
60 }
61 return errors.New("timeout")
62}
63
64func stackFatalf(t *testing.T, f string, args ...any) {
65 lines := make([]string, 0, 32)

Callers 2

WaitFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected