Skip to content

Merge pull request #130 from ntut-xuan/v0.2.0-rc #1402

Merge pull request #130 from ntut-xuan/v0.2.0-rc

Merge pull request #130 from ntut-xuan/v0.2.0-rc #1402

name: Unit tests on backend
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install -r requirements.txt
pip install pytest
pip install pytest-cov
- name: Unit tests with Pytest
working-directory: ./backend
run: python -m pytest tests/unit_tests --cov-config .coveragerc --cov . --cov-report xml
- name: Upload coverage reports to Codecov with GitHub Action
uses: codecov/codecov-action@v3