MCPcopy Create free account
hub / github.com/egonelbre/exp / timeout

Function timeout

queues/testutils_test.go:14–24  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

12)
13
14func timeout() chan int {
15 done := make(chan int)
16 go func() {
17 select {
18 case <-time.After(testTimeout):
19 panic("Timeout")
20 case <-done:
21 }
22 }()
23 return done
24}
25
26func testReturn(t *testing.T, got interface{}, wasOk bool, expected interface{}, expectedOk bool) {
27 if wasOk != expectedOk {

Callers 3

fifoTestFunction · 0.85
lifoTestFunction · 0.85
runParallelTestFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected