Skip to content

Fix flaky TestConversionURLValues when run with -shuffle#165

Open
hanzei wants to merge 1 commit intomasterfrom
fix-flaky-url-values-test
Open

Fix flaky TestConversionURLValues when run with -shuffle#165
hanzei wants to merge 1 commit intomasterfrom
fix-flaky-url-values-test

Conversation

@hanzei
Copy link
Collaborator

@hanzei hanzei commented Mar 4, 2026

Tests that call SetURLValuesSliceKeySuffix mutate package-level global state without restoring it, causing TestConversionURLValues and TestConversionURLQuery to fail when shuffled to run after them

Fixes #164

Tests that call SetURLValuesSliceKeySuffix mutate package-level global
state without restoring it. When shuffled to run before
TestConversionURLValues, the suffix is "" or "[i]" instead of "[]",
causing key mismatches. Add t.Cleanup to restore the default suffix.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@hanzei hanzei requested a review from geseq March 4, 2026 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Failing TestConversionURLValues

1 participant