Combine unit tests into a single directory #1310
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
We previously had a separate set of unit tests for each platform; now that we're adding platforms (3 already, a 4th about to be added for ARM) it's starting to become unwieldy. Instead, this PR combines all the unit tests into a single directory, (attempting to) run every unit test on every platform. The Windows-only tests will run on Linux too, generating the corresponding error message (thus obviating the need for the previous
invalidtests to make sure they don't work on Linux), etc.To preserve the existing behavior of making sure that
invalidtests always fail, if the test name begins withinvalid-the code will expect that the test should fail on every platform.Related issue
b/274913389 and b/283086085
How has this been tested?
Unit tests continue to pass. I carefully moved the existing golden files into place and verified the diffs by hand before using
go test . -updateto generate the missing golden files.Checklist: