This PR addresses issue #1 by adding discrete linting and testing steps. The main.yml script is structured in a way that other steps can be added as needed.
Create lint.yml job to be used in the composite main.yml job
Employed a matrix-based approach (looping through hyper parameters such as python-version) to testing in test.yml.
Create a main.yml script that performs lint checks then tests the code
Considerations
I expect that the CI actions and processes will evolve as the project matures
The environment must be setup for each action (i.e. testing on python 3.11 and linting). At the moment the entire CI process is finished in under two minutes
If we do not wish to use a matrix-based approach to testing we can combine the lint and test jobs into a single job that can re-use setup code. If we want to avoid matrix-based testing at this time we can easily combine the actions into a single workflow
The decision to split linting and testing in the CI process was informed by a desire for readable output in the case of errors. Due to the size of the project I felt that the small time tradeoff is worth enhanced readability.
Summary
This PR addresses issue #1 by adding discrete linting and testing steps. The
main.yml
script is structured in a way that other steps can be added as needed.Example of action summary: https://github.com/frank113/pycountrycode/actions/runs/5428515778
Issues Addressed
1
Changes Made
flake8
,black
andisort
to dependenciespoetry.lock
in accordance with updatedpyproject.toml
dependenciesreplace_regex
helper functionlint.yml
job to be used in the compositemain.yml
jobpython-version
) to testing intest.yml
.main.yml
script that performs lint checks then tests the codeConsiderations
lint
andtest
jobs into a single job that can re-use setup code. If we want to avoid matrix-based testing at this time we can easily combine the actions into a single workflowOther
Looking forward to working on this package!