Skip to content

Commit

Permalink
add GitHub Action for unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
SimeonEhrig committed Jan 23, 2024
1 parent 3207d45 commit f7edaba
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/codeCoverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
with:
fetch-depth: 2
- name: Setup Python
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 3.12
- name: Install bashi
Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/testDeploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: test-and-deploy
on: [push, pull_request]
jobs:
formatter:
name: runner black code formatter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: rickstaa/action-black@v1
with:
black_args: ". --check"

unit-tests:
runs-on: ubuntu-latest
needs: formatter
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
name: Run unit tests with Python ${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Install bashi
run: |
pip install .
- name: run unit tests
run: python -m unittest

0 comments on commit f7edaba

Please sign in to comment.