-
-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix unreliable test #119
Comments
Hi, It's also reported at https://bugs.debian.org/923804, and
Could you help looking at this issue recently? It's a blocking issue in Debian to keep this library and many reverse dependencies :( I tried reading the code, but I'm lost with the different time durations in this test. Thanks |
I can't make this happen locally and it hasn't happened in the travis builds for ages :-( Can you see if this fixes it? diff --git a/watchdog_reader_test.go b/watchdog_reader_test.go
index 8e8f013..08dabff 100644
--- a/watchdog_reader_test.go
+++ b/watchdog_reader_test.go
@@ -98,7 +98,7 @@ func TestWatchdogReaderOnSlowNetwork(t *testing.T) {
delayPerByte: 200 * time.Millisecond / time.Duration(len(byteString)),
}
- timer, firedChan := setupTimer(10 * time.Millisecond)
+ timer, firedChan := setupTimer(100 * time.Millisecond)
wr := newWatchdogReader(reader, 190*time.Millisecond, timer)
//use io.ReadFull instead of ioutil.ReadAll here because ReadAll already does |
@ncw thanks for the patched. I've built 100 times, and 0 failure with this patch, compared to 42/100 failures for the origin one. |
I've committed that patch and tagged a release with it in v1.0.45 Thank you for testing :-) |
The commit is 3623852 - this didn't get autolinked for some reason... |
This keeps failing :-(
The text was updated successfully, but these errors were encountered: