tailscale/net/nettest
Josh Bleecher Snyder 7c1a9e8616 net/nettest: de-flake tests on Windows
Windows has a low resolution timer.
Some of the tests assumed that unblock takes effect immediately.

Consider:

t := time.Now()
elapsed := time.Now().After(t)

It seems plausible that elapsed should always be true.
However, with a low resolution timer, that might fail.

Change time.Now().After to !time.Now().Before,
so that unblocking always takes effect immediately.

Fixes #873.
2021-01-15 18:21:56 -08:00
..
conn.go net/nettest: new package with net-like testing primitives 2020-03-12 14:42:48 -04:00
pipe.go net/nettest: de-flake tests on Windows 2021-01-15 18:21:56 -08:00
pipe_test.go net/nettest: remove pointless checks in tests 2021-01-15 18:21:56 -08:00