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

Support running tests on CI for each supported minor version of Go #206

Open
rturner3 opened this issue Dec 13, 2022 · 1 comment
Open

Comments

@rturner3
Copy link
Collaborator

Sometimes there are changes to the Go standard libraries that can break test expectations, e.g. different error text like in #205. Since the library supports older versions of Go, it would be nice to have the unit tests run on CI against each supported minor version of Go to account for these changes in standard library behavior. This would also gives developers assurances that they are writing test expectations correctly.

This also introduces a requirement to somehow communicate the version of Go being used in the environment to the unit test code, e.g. through a build tag, environment variable.

@azdagron
Copy link
Member

This also introduces a requirement to somehow communicate the version of Go being used in the environment to the unit test code

There are implicit build tags for go versions that we can use, e.g:

//go:build go1.17

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 a pull request may close this issue.

2 participants