Skip to content

chore(version): v1.1.0 #11

chore(version): v1.1.0

chore(version): v1.1.0 #11

Workflow file for this run

# Github CI from: https://devsjc.github.io/blog/20240627-the-complete-guide-to-pyproject-toml/
name: Python CI
on: ["push"]
jobs:
build-venv:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Restore cached virtualenv
id: restore-cache
uses: actions/cache/restore@v3
with:
path: ./venv
key: ${{ runner.os }}-venv-${{ hashFiles('**/pyproject.toml') }}
- name: Build venv
run: |
python -m venv ./venv
./venv/bin/python -m pip install .
if: steps.restore-cache.outputs.cache-hit != 'true'
- name: Cache virtualenv
uses: actions/cache/save@v3
with:
path: ./venv
key: ${{ steps.restore-cache.outputs.cache-primary-key }}
if: steps.restore-cache.outputs.cache-hit != 'true'
test-unit:
runs-on: ubuntu-latest
needs: build-venv
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Restore cached virtualenv
uses: actions/cache/restore@v3
with:
path: ./venv
key: ${{ runner.os }}-venv-${{ hashFiles('**/pyproject.toml') }}
- name: Install package
run: ./venv/bin/python -m pip install .
- name: Run tests
run: ./venv/bin/python -m unittest -v