Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: enable test shuffle and fix test #1097

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

alexandear
Copy link
Contributor

@alexandear alexandear commented Nov 4, 2024

This PR extends go test with -shuffle flag and fixes failing TestXDGConfigDirNoFile:

--- FAIL: TestXDGConfigDirNoFile (0.00s)
    main_test.go:80: got "", wanted "/tmp-iofs/xdg/config/revive.toml"
FAIL

The shuffle flag description from https://pkg.go.dev/cmd/go#hdr-Testing_flags:

-shuffle off,on,N
    Randomize the execution order of tests and benchmarks.
    It is off by default. If -shuffle is set to on, then it will seed
    the randomizer using the system clock. If -shuffle is set to an
    integer N, then N will be used as the seed value. In both cases,
    the seed will be reported for reproducibility.

@alexandear alexandear changed the title chore: enable test shuffle chore: enable test shuffle and fix test Nov 4, 2024
@alexandear
Copy link
Contributor Author

Lint issue fixed by #1096

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.

1 participant