Bump pytest from 6.2.4 to 7.4.0 in /tools/deps #4470
Workflow file for this run
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: Unit tests | |
on: | |
pull_request: | |
paths: | |
- ".github/workflows/unit_tests.yml" | |
- "nxdrive/**/*.py" | |
- "tests/*.py" | |
- "tests/unit/*.py" | |
- "tools/deps/*.txt" | |
push: | |
branches: [master] | |
paths: | |
- "nxdrive/**/*.py" | |
- "tests/*.py" | |
- "tests/unit/*.py" | |
jobs: | |
unit-tests-linux: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.9 # XXX_PYTHON | |
- uses: actions/cache@v3 | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
restore-keys: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
- uses: actions/cache@v3 | |
with: | |
path: .tox | |
key: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
restore-keys: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
- name: Install tox | |
run: python -m pip install -r tools/deps/requirements-tox.txt | |
- name: Unit tests | |
run: tox -e unit | |
- name: Upload coverage to Codecov | |
if: ${{ success() }} || ${{ failure() }} | |
uses: codecov/[email protected] | |
with: | |
files: ./coverage.xml | |
flags: unit | |
env_vars: OS,PYTHON | |
unit-tests-macos: | |
runs-on: "macos-latest" | |
env: | |
SYSTEM_VERSION_COMPAT: 0 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.9 # XXX_PYTHON | |
- uses: actions/cache@v3 | |
with: | |
path: ~/Library/Caches/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
restore-keys: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
- uses: actions/cache@v3 | |
with: | |
path: .tox | |
key: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
restore-keys: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
- name: Install tox | |
run: python -m pip install -r tools/deps/requirements-tox.txt | |
- name: Unit tests | |
run: tox -e unit | |
- name: Upload coverage to Codecov | |
if: ${{ success() }} || ${{ failure() }} | |
uses: codecov/[email protected] | |
with: | |
files: ./coverage.xml | |
flags: unit | |
env_vars: OS,PYTHON | |
unit-tests-windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.9 # XXX_PYTHON | |
architecture: "x86" | |
- uses: actions/cache@v3 | |
with: | |
path: ~\AppData\Local\pip\Cache | |
key: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
restore-keys: ${{ runner.os }}-pip-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
# Cannot be used for now: OSError: [WinError 193] %1 is not a valid Win32 application | |
# - uses: actions/cache@v3 | |
# with: | |
# path: .tox | |
# key: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
# restore-keys: ${{ runner.os }}-tox-${{ hashFiles('tools/deps/requirements-test.txt', 'tools/deps/requirements-tox.txt') }} | |
- name: Install tox | |
run: python -m pip install -r tools/deps/requirements-tox.txt | |
- name: Unit tests | |
run: tox -e unit | |
- name: Upload coverage to Codecov | |
if: ${{ success() }} || ${{ failure() }} | |
uses: codecov/[email protected] | |
with: | |
files: ./coverage.xml | |
flags: unit | |
env_vars: OS,PYTHON |