Skip to content

Go: Check more things while running tests #19491

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

Draft
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

owen-mc
Copy link
Contributor

@owen-mc owen-mc commented May 14, 2025

Originally I added the following flags: --fail-on-trap-errors, --check-undefined-labels, --check-unused-labels, --check-repeated-labels, --check-redefined-labels, --check-use-before-definition. I then had to remove --check-unused-labels because it was produced results and making tests fail (because of --fail-on-trap-errors).

@owen-mc owen-mc added the no-change-note-required This PR does not need a change note label May 14, 2025
@github-actions github-actions bot added the Go label May 14, 2025
@owen-mc
Copy link
Contributor Author

owen-mc commented May 15, 2025

The CI has highlighted a db inconsistency that only happens on windows: the container parent of "C:/a" is recorded as both "C:/" and "C:".

owen-mc added 2 commits May 15, 2025 13:43
This makes the test slightly more thorough.
In go, an interface with value nil does not compare equal to nil. This
is known as "typed nils". So our existing nil checks weren't working,
which shows why we needed more nil checks inside the type switches. The
solution is to explicitly check for each type we care about.
@owen-mc owen-mc force-pushed the go/add-test-flags branch from a093b3d to 564314b Compare May 15, 2025 12:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Go no-change-note-required This PR does not need a change note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant