From d3144fa1d29022b6376b73458ae0304e0f7acd0d Mon Sep 17 00:00:00 2001 From: Marc-Antoine Ruel Date: Tue, 23 Oct 2018 05:03:29 -0600 Subject: [PATCH] gpioutil: fix a race condition in TestDebounce_WaitForEdge_Got --- experimental/devices/gpioutil/debounce_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/experimental/devices/gpioutil/debounce_test.go b/experimental/devices/gpioutil/debounce_test.go index 8fcf85f..75a18ae 100644 --- a/experimental/devices/gpioutil/debounce_test.go +++ b/experimental/devices/gpioutil/debounce_test.go @@ -86,7 +86,7 @@ func TestDebounce_WaitForEdge_Got(t *testing.T) { t.Fatal(err) } f.EdgesChan <- gpio.Low - if !p.WaitForEdge(0) { + if !p.WaitForEdge(-1) { t.Fatal("expected edge") } }