Skip to content

Create unittest.yml

Create unittest.yml #1

Workflow file for this run

name: Python Unittest on Push and PR
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build-and-test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.10] # Currently testing only with 3.10, but easy to add more
steps:
- name: Check out the repository
uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run unittests
run: python -m unittest discover -s tests