Update the dev status classifier to alpha #348
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: Tests | |
on: | |
push: | |
paths: | |
- "**.py" | |
- pyproject.toml | |
- poetry.lock | |
- .github/workflows/poetry-constraint.txt | |
- .github/workflows/env-markers/poetry-install-only-main-test.txt | |
- .github/workflows/tests.yml | |
branches: | |
- main | |
- "releases/**" | |
pull_request: | |
paths: | |
- "**.py" | |
- pyproject.toml | |
- poetry.lock | |
- .github/workflows/poetry-constraint.txt | |
- .github/workflows/env-markers/poetry-install-only-main-test.txt | |
- .github/workflows/tests.yml | |
branches: | |
- main | |
- "releases/**" | |
workflow_dispatch: | |
schedule: | |
- cron: "0 15 * * *" # Daily at 6pm Israel standard time | |
jobs: | |
tests: | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest] | |
python-version: ["3.11", "3.12"] | |
runs-on: ${{ matrix.os }} | |
env: | |
PY_COLORS: 1 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Poetry | |
run: pipx install --pip-args="-c .github/workflows/poetry-constraint.txt" poetry | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
cache: poetry | |
cache-dependency-path: | | |
poetry.lock | |
.github/workflows/env-markers/poetry-install-only-main-test.txt | |
- name: Install dependencies | |
run: poetry install --only main,test | |
- name: Run live tests (needing an internet connection) | |
run: poetry run coverage run -m pytest -m live | |
- name: Run static tests | |
if: github.event_name != 'schedule' | |
run: poetry run coverage run -am pytest -m "not live" --disable-network | |
- name: Report coverage | |
if: github.event_name != 'schedule' | |
run: poetry run coverage report | |
# The following step will be removed when all the project is covered with tests | |
- name: Maintain 100% coverage on tested modules | |
if: github.event_name != 'schedule' | |
run: | | |
poetry run coverage report --fail-under 100 \ | |
xil/_currencies.py \ | |
xil/_headers.py \ | |
xil/_df_normalizer.py \ | |
xil/onezero.py \ |