Skip to content

test: TestRoutePatterns410 hidden-hop test is flaky across a second boundary (two time.Now seeds) #483

Closed

Description

@dborup

Problem

TestRoutePatterns410_HiddenHopWithTrafficLooksUnknown/observer_blacklist (added in #453) failed in CI with a one-second firstSeen split (19:49:05Z vs 19:49:06Z). The test seeds its fixture from two separate time.Now() calls, one near line 45 and one near line 722. When those fall in different seconds, the hidden and unknown responses differ only in that timestamp, and the "byte-identical" comparison fails. It was reported in the round-2 review of #478 (G6) and is unrelated to that PR.

Task

Make the test deterministic. Use one fixed reference time for every seed, or compare with the timestamp normalized only where the test's intent allows it. Do not weaken the hidden-vs-unknown indistinguishability check, which is the privacy property from #410. No retries.

Acceptance criteria

50 consecutive go test -run TestRoutePatterns410 -count=50 runs pass. A mutant that makes a hidden hop distinguishable still fails.

Activity

  1. dborup commented on Oct 15, 2026

    @dborup
    OwnerAuthor

    Fixed by #484 (merged as 8f01d3787c2ee51ca20c069241c995c0939964a7).Fixed by #484: TestRoutePatterns410 seeds from one fixed reference time, so it no longer flakes across a second boundary; the privacy check is unchanged (APPROVE, CI green).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions