Skip to content

Start tests

Start tests #51

Workflow file for this run

name: Run Tests
on:
pull_request:
push:
branches: [master, main, dev]
jobs:
test:
name: Python ${{ matrix.python-version }}
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Display Python version
run: python -c "import sys; print(sys.version)"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Run eyeball tests
run: python tests/eyeball.py
- name: Test with pytest
run: |
pip install pytest
pytest tests/ --maxfail=3 --showlocals --color=yes -v
##steps:
#- uses: runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ubuntu-latest, macos-latest, windows-latest]
# python-version: ["3.9", "3.10", "3.11", "pypy3.9", "pypy3.10"]
# exclude:
# - os: macos-latest
# python-version: "3.9"
# - os: windows-latest
# python-version: "3.9"
# pip install pytest pytest-cov
# pytest tests.py --doctest-modules --junitxml=junit/test-results.xml --cov=com --cov-report=xml --cov-report=html
#- name: Lint with Ruff
# run: |
# pip install ruff
# ruff --output-format=github .
# continue-on-error: true
# - name: Lint with flake8
# run: |
# # stop the build if there are Python syntax errors or undefined names
# flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
# flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics