Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(514)

Issue 6920047: code review 6920047: log/syslog: fix flakey test on slow hosts (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
9 years, 9 months ago by dfc
Modified:
9 years, 9 months ago
Reviewers:
CC:
golang-dev, bradfitz
Visibility:
Public.

Description

log/syslog: fix flakey test on slow hosts Fixes issue 4467. The syslog tests can fail if the timeout fires before the data arrives at the mock server. Moving the timeout onto the goroutine that is calling ReadFrom() and always processing the data returned before handling the error should improve the reliability of the test.

Patch Set 1 #

Patch Set 2 : diff -r 3c932286e5f5 https://code.google.com/p/go #

Patch Set 3 : diff -r ec3ae5b98922 https://code.google.com/p/go #

Total comments: 1

Patch Set 4 : diff -r 27b36f9dd377 https://code.google.com/p/go #

Unified diffs Side-by-side diffs Delta from patch set Stats (+5 lines, -5 lines) Patch
M src/pkg/log/syslog/syslog_test.go View 1 2 3 2 chunks +5 lines, -5 lines 0 comments Download

Messages

Total messages: 3
dfc
Hello golang-dev@googlegroups.com, I'd like you to review this change to https://code.google.com/p/go
9 years, 9 months ago (2012-12-12 02:47:48 UTC) #1
bradfitz
LGTM But I'm not optimistic it'll make much difference. https://codereview.appspot.com/6920047/diff/3002/src/pkg/log/syslog/syslog_test.go File src/pkg/log/syslog/syslog_test.go (right): https://codereview.appspot.com/6920047/diff/3002/src/pkg/log/syslog/syslog_test.go#newcode23 src/pkg/log/syslog/syslog_test.go:23: ...
9 years, 9 months ago (2012-12-12 20:02:35 UTC) #2
dfc
9 years, 9 months ago (2012-12-13 05:26:42 UTC) #3
*** Submitted as https://code.google.com/p/go/source/detail?r=ecb968e2db24 ***

log/syslog: fix flakey test on slow hosts

Fixes issue 4467.

The syslog tests can fail if the timeout fires before the data arrives at the
mock server. Moving the timeout onto the goroutine that is calling ReadFrom()
and always processing the data returned before handling the error should improve
the reliability of the test.

R=golang-dev, bradfitz
CC=golang-dev
https://codereview.appspot.com/6920047
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b