L: for { select { case <-ch1: go func() { scenario.LoadIndexPage(origins) time.Sleep(500 * time.Millisecond) ch1 <- struct{}{} }() case <-ch2: go func() { scenario.DrawOnRandomRoom(origins) time.Sleep(500 * time.Millisecond) ch2 <- struct{}{} }() case <-timeoutCh: break L } }