TestAliasCallsAreTheGatewaysNotDirect stamped its direct call 6 minutes
before time.Now() and asked Direct(Today), so in the six minutes after
local midnight the call was yesterday's: red on mote at 00:00 PST and on
macOS CI at 00:07 UTC (run 43523008440). TestLoopsCountedPerModel and
TestRequestsCountedOnceWithTheirRetries do the same with stamps up to 9 s
back (same class). All three now take their time from holdClock at a
fixed noon, as TestPeriodsReadTheClock does.
Run (mica, at 783b69b8c + this):
- the three tests -count=3 in TZ=UTC and TZ=Asia/Shanghai: ok
(and in UTC, Asia/Shanghai, America/Los_Angeles on mote: ok)
- broken by hand: held at 00:00:03 instead of noon, all three red
(gateway_alias_test.go:44 "0 calls", loop_count_test.go:55,
retried_requests_test.go:55), so they read the held clock
- go test -count=1 ./internal/usage: ok 53s; go vet ./internal/usage: ok
Not run: the full suite (test-only change in one package).
Not changed: #6474 (TestWalletCapHolds, the 5 minutes before midnight)
is another package's sibling and stays open.