Skip to content

ENH: add missing type hinting #54

ENH: add missing type hinting

ENH: add missing type hinting #54

Workflow file for this run

name: Linux Tests
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
os: [ubuntu-latest]
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install building tools
run: |
pip install build twine
- name: Build package
run: |
python -m build --wheel
- name: Package differences computation
run: |
if [[ $(diff -r ./gearpy ./build/lib/gearpy | grep -v __pycache__ | wc -m) == 0 ]]; then
echo "packages_are_equal=true" >> $GITHUB_ENV
else
echo "packages_are_equal=false" >> $GITHUB_ENV
fi
- name: Condition check
if: env.packages_are_equal == 'false'
uses: actions/github-script@v3
with:
script: |
core.setFailed('Compiled package different from source package.')
- name: Install build package
run: |
pip install .[test]
- name: Fetch
uses: actions/checkout@master
- name: Run tests
run: |
python -m pytest --verbose --disable-pytest-warnings --cov=gearpy --cov-report=xml:linux_coverage.xml -nauto
- name: Upload
uses: codecov/codecov-action@v2
with:
files: ./linux_coverage.xml
token: ${{ secrets.CODECOV_TOKEN }}