-
Notifications
You must be signed in to change notification settings - Fork 61
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
Tests: Skip OPS-based integration tests when no credentials are defined #86
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #86 +/- ##
=======================================
Coverage 99.53% 99.53%
=======================================
Files 18 18
Lines 428 428
=======================================
Hits 426 426
Misses 2 2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
While it will only cover parts of the test suite, which is unfortunate, at least it will not break. This is relevant for CI/GHA, because pull requests submitted by external contributors do not have access to the OPS credentials per GitHub Actions Secrets. C'est la vie.
By centralizing common configuration settings into `pyproject.toml`, the invocation is more universal, and the configuration does not need to be maintained at different spots.
Hi @gsong. I am not sure if you are into reviewing my boring maintenance patches, or not. Occasionally, I let the PR open for a while to give you the chance to review it, but if you think it isn't necessary, I will adjust my workflow to always merge them right away if I consider them not too critical / if they do not touch the code base at all. |
Not boring at all! I really appreciate your stewardship of this tool. Feel free to open PR and @mention me or mark me as reviewer. But no need to wait for me to merge stuff. I would like to keep up to date as much as possible, but probably like you, that time comes in spurts. |
Problem
GH-81 demonstrated that the software tests run on behalf of GHA fail on external contributions, because they do not have access to the OPS credentials per GitHub Actions Secrets. Bummer.
Solution
This patch will make running OPS-based tests optional. That this decreases the coverage of the code base, is unfortunate, but at least, tests will stop failing on CI. C'est la vie.
Outlook
A possible solution for a subsequent iteration would be to emulate/mock a OPS service backend, so integration tests could be synthesized. I think @gsong may have used such a technique on a previous version?