Update to calendar_data.py #54
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
name: Run Tests with Pytest | |
on: | |
push: | |
branches: | |
- '*' | |
jobs: | |
unit-tests-pytest: | |
name: Run unit tests with pytest | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install system level libraries | |
run: | | |
sudo apt-get update | |
sudo apt-get -y install libpq-dev gcc | |
- name: Checkout code from remote origin. | |
uses: actions/checkout@v2 | |
- name: Add project root to PYTHONPATH | |
run: | | |
import os | |
import sys | |
sys.path.append(os.path.abspath('.')) | |
shell: python | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install pytest pytest-cov pytest-json-report pytest-freezegun | |
pip install -r requirements.txt | |
- name: Print current working directory | |
run: | | |
pwd | |
ls -lart | |
- name: Run tests | |
run: | | |
pytest --cov=. --cov-config=.coveragerc --cov-report=html:coverage_report --json-report --json-report-file=test_report.json tests/ | |
env: | |
PYTHONPATH: ${{ github.workspace }} | |
- name: Upload Coverage and test reports | |
uses: actions/upload-artifact@v2 | |
with: | |
name: test-reports | |
path: | | |
coverage_report/ | |
test_report.json |