Skip to content

update tests

update tests #19

Workflow file for this run

name: Run Tests
on:
push:
branches:
- '**'
pull_request:
jobs:
run-tests:
runs-on: ubuntu-20.04
strategy:
matrix:
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install Requirements
run: |
python -c "import sys; print(sys.version)"
pip install -r requirements-dev.txt
python setup.py install
- name: Run tests
env:
TMDB_APIKEY: ${{ secrets.TMDB_APIKEY }}
TMDB_SESSION: ${{ secrets.TMDB_SESSION }}
TMDB_V4_ACCESS: ${{ secrets.TMDB_V4_ACCESS }}
TMDB_V4_TOKEN: ${{ secrets.TMDB_V4_TOKEN }}
TMDB_USERNAME: ${{ secrets.TMDB_USERNAME }}
TMDB_PASSWORD: ${{ secrets.TMDB_PASSWORD }}
PAT: ${{ secrets.PAT }}
LOCAL: False
run: coverage run -m pytest -s --cov tmdbapis --cov-report xml tests/test*
- name: Codecov coverage reports
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.xml
tag-new-versions:
runs-on: ubuntu-latest
if: ${{ success() }}
needs: [run-tests]
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.PAT }}
fetch-depth: 2
- uses: salsify/[email protected]
with:
version-command: |
cat VERSION