2022-12-13 22:16:52 +00:00
|
|
|
name: Tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ "main", "release"]
|
|
|
|
paths:
|
|
|
|
- '.github/workflows/test.yml'
|
2022-12-14 09:41:15 +00:00
|
|
|
- 'src/**'
|
2022-12-13 22:16:52 +00:00
|
|
|
- 'Makefile'
|
|
|
|
- 'requirements.test.txt'
|
|
|
|
pull_request:
|
|
|
|
branches: [ "main", "release"]
|
|
|
|
paths:
|
|
|
|
- '.github/workflows/test.yml'
|
2022-12-14 09:41:15 +00:00
|
|
|
- 'src/**'
|
2022-12-13 22:16:52 +00:00
|
|
|
- 'Makefile'
|
|
|
|
- 'requirements.test.txt'
|
|
|
|
schedule:
|
|
|
|
- cron: "5 0 * * 1"
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
test:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
API_KEY: ${{ secrets.API_KEY }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
2024-12-16 23:19:46 +00:00
|
|
|
python-version: ["3.12"]
|
2022-12-13 22:16:52 +00:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v3
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
pip install --upgrade pip
|
2024-10-05 21:20:21 +00:00
|
|
|
pip install -U -r requirements.test.txt
|
2022-12-13 22:16:52 +00:00
|
|
|
|
|
|
|
- name: Test
|
|
|
|
run: make tests
|
|
|
|
|
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
|
|
|
token: ${{ secrets.CODECOV_TOKEN }}
|
2023-12-13 23:37:32 +00:00
|
|
|
files: ${{github.workspace}}/coverage/coverage.xml
|
2022-12-13 22:16:52 +00:00
|
|
|
fail_ci_if_error: true
|
|
|
|
verbose: true
|