Commit 1fb82ad71050dceebe7cb52aff4a48827b9ba8f0
1 parent
859a3c68
Run unittests automatically
Use github actions for Continuous Integration
Showing
1 changed file
with
24 additions
and
0 deletions
.github/workflows/unittests.yml
0 → 100644
| 1 | +name: Python package | ||
| 2 | + | ||
| 3 | +on: [push] | ||
| 4 | + | ||
| 5 | +jobs: | ||
| 6 | + build: | ||
| 7 | + runs-on: ubuntu-latest | ||
| 8 | + strategy: | ||
| 9 | + matrix: | ||
| 10 | + python-version: ["3.9"] | ||
| 11 | + | ||
| 12 | + steps: | ||
| 13 | + - uses: actions/checkout@v3 | ||
| 14 | + - name: Set up Python ${{ matrix.python-version }} | ||
| 15 | + uses: actions/setup-python@v3 | ||
| 16 | + with: | ||
| 17 | + python-version: ${{ matrix.python-version }} | ||
| 18 | + - name: Install dependencies | ||
| 19 | + run: | | ||
| 20 | + python -m pip install --upgrade pip | ||
| 21 | + if [ -f requirements.txt ]; then pip install -r requirements.txt; fi | ||
| 22 | + - name: Test with unittests | ||
| 23 | + run: | | ||
| 24 | + python -m unittest discover | ||
| 0 | \ No newline at end of file | 25 | \ No newline at end of file |