[SDTEST-3172] Add runtime tags override to skip test files locally #27
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.
What does this PR do?
Adds a command line parameter and corresponding environment variable to provide an override for runtime tags collected by Datadog libraries.
It is important because when using Test Impact Analysis, skippable tests are scoped by runtime environment (OS, architecture, language version). This means tests skipped in the Linux CI won't automatically be skipped on the macOS development machine because the runtime tags differ.
The
--runtime-tagsoption lets you override your local runtime tags to match your CI environment, enabling users to benefit from Test Impact Analysis locally without re-running their entire test suite.The documentation about this feature is added to README.md
Motivation
A conversation with early adopters about a possibility to use
ddtestto run a subset of tests in the local development environmentAdditional Notes
Unfortunately, this will not make the Datadog Test Optimization library to skip the tests locally - but it can be used to skip locally the complete test files where all tests are skipped by test impact analysis
How to test the change?
Was manually tested using anmarchenko/forem project