Support regex matching when parsing CI configuration file #111
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.
Support regex matching for tag/branches when parsing
config/ci.json
file. This is to allow using regexdev-.*
patterns to specify test configuration for all dev branches, e.g.I added a python script for parsing the file so I could just use the standard python regex library for string matching. This meant it was also easier to add tests.
The order for finding a key's (e.g. "markers") value now is:
qa
)dev-1deg-.*
beforedev-.*
To avoid the composite action modifying the caller workflow environment, I've set
update-environment: false
insetup-python
action, and called the python executable directly using the output of the action (see https://github.com/actions/setup-python/blob/main/docs/advanced-usage.md#using-update-environment-flag).Similarly to avoid checking out the
model-config-tests
repository to obtain theparse-file.py
file of the correct version, I am usinggithub.action_path
to access the files in the.github/actions/pares-ci-config
directory (see https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs#github-context).References #99