Skip to content

Merge branch 'stable' into unstable #567

Merge branch 'stable' into unstable

Merge branch 'stable' into unstable #567

Workflow file for this run

name: pytest
on: push
jobs:
pytest:
name: runner / pytest tests
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
extras:
- .
- .[speedup]
- .[voice]
- .[all]
python-version:
- "3.10"
- "3.11"
include:
- extras: .[all]
python-version: "3.10"
RUN_TESTBOT: true
- extras: .[all]
python-version: "3.11"
RUN_TESTBOT: true
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2.3.1
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install ffmpeg & opus
run: sudo apt-get update && sudo apt-get install ffmpeg libopus-dev
- name: Install pytest
run: |
pip install wheel
pip install -e ${{ matrix.extras }}
pip install .[tests]
- name: Run Tests
env:
BOT_TOKEN: ${{ secrets.BOT_TOKEN }}
RUN_TESTBOT: ${{ matrix.RUN_TESTBOT }}
run: |
pytest --cov=./ --cov-report xml:coverage.xml
coverage xml -i
- name: Upload Coverage
run: |
curl -Os https://uploader.codecov.io/latest/linux/codecov
chmod +x codecov
./codecov
- name: Publish Test Report
uses: mikepenz/action-junit-report@v3
if: always() # always run even if the previous step fails
with:
report_paths: '**/TestResults.xml'
check_name: 'Pytest Results'