Skip to content

Instantly share code, notes, and snippets.

@BrianHicks
Created July 13, 2015 20:01
Show Gist options
  • Save BrianHicks/c8629a864f3b70e2acc3 to your computer and use it in GitHub Desktop.
Save BrianHicks/c8629a864f3b70e2acc3 to your computer and use it in GitHub Desktop.
var val MaybeKVPairs
select {
case val = <-pairs:
case <-time.After(1 * time.Second):
t.Error("no value received before timeout")
t.Fail()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment