-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #195 from xyz2tex/187-improve-test-coverage
ADD: Add tests to improve coverage
- Loading branch information
Showing
34 changed files
with
1,778 additions
and
665 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,5 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: psf/black@stable | ||
with: | ||
version: "23.1.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,29 +9,46 @@ jobs: | |
|
||
steps: | ||
- name: Checkout branch | ||
uses: actions/checkout@v3 | ||
uses: actions/checkout@v4 | ||
|
||
- name: Get changed files | ||
id: changed-files | ||
uses: tj-actions/changed-files@v41 | ||
id: changed-python | ||
uses: tj-actions/changed-files@v44 | ||
with: | ||
files: "**/*.py" | ||
files: | | ||
**.py | ||
#fetch_depth: 0 | ||
|
||
- name: Set up Python all python version | ||
if: steps.chaged-files.output.any_changed == 'true' | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: 3.9 | ||
|
||
- name: Install dependencies | ||
if: steps.chaged-files.output.any_changed == 'true' | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
run: sudo apt-get install libgirepository1.0-dev | ||
|
||
- run: pip install --upgrade pip | ||
if: steps.chaged-files.output.any_changed == 'true' | ||
- run: pip install . | ||
if: steps.chaged-files.output.any_changed == 'true' | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
|
||
- run: pip install poetry | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
|
||
- run: poetry install --with dev | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
|
||
- name: Run Test | ||
if: steps.chaged-files.output.any_changed == 'true' | ||
run: python -m unittest | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
run: poetry run coverage run -m unittest | ||
|
||
- name: Create coverage xml | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
run: poetry run coverage xml | ||
|
||
- name: Get Cover | ||
if: steps.changed-python.outputs.any_changed == 'true' | ||
uses: orgoro/[email protected] | ||
with: | ||
coverageFile: coverage.xml | ||
token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.