mirror of
https://github.com/django-q2/django-q2.git
synced 2026-09-15 21:47:53 +08:00
Codecov_fixes (#562)
* Trying to get codecov working again * Use poetry run * Defining testing extras * Fixing codecov output files * Try installing the right Django version and show relevant upload tags * Cover only project files
This commit is contained in:
22
.github/workflows/test.yml
vendored
22
.github/workflows/test.yml
vendored
@@ -33,7 +33,6 @@ jobs:
|
||||
options: --entrypoint redis-server
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: codecov/codecov-action@v1
|
||||
- name: Set up Python ${{ matrix.python-version }}
|
||||
uses: actions/setup-python@v2
|
||||
with:
|
||||
@@ -41,14 +40,21 @@ jobs:
|
||||
- name: Install dependencies with Django ${{ matrix.django }}
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install -q django==${{ matrix.django }}
|
||||
pip install -r requirements.txt
|
||||
pip install pytest --upgrade
|
||||
pip install pytest-django codecov sphinx poetry
|
||||
poetry install
|
||||
pip install poetry
|
||||
poetry add "django==${{ matrix.django }}"
|
||||
poetry install -E testing
|
||||
- name: Run Tests
|
||||
run: |
|
||||
coverage run --source=django_q -m py.test
|
||||
poetry run pytest --cov=./django_q --cov-report=xml
|
||||
- name: Upload coverage
|
||||
uses: codecov/codecov-action@v1
|
||||
env:
|
||||
PYTHON: ${{ matrix.python-version }}
|
||||
DJANGO: ${{ matrix.django }}
|
||||
with:
|
||||
token: ${{ secrets.CODECOV_TOKEN }}
|
||||
env_vars: PYTHON, DJANGO
|
||||
fail_ci_if_error: true
|
||||
- name: Build docs
|
||||
run: |
|
||||
sphinx-build -b html -d docs/_build/doctrees -nW docs docs/_build/html
|
||||
poetry run sphinx-build -b html -d docs/_build/doctrees -nW docs docs/_build/html
|
||||
|
||||
Reference in New Issue
Block a user