Skip to content

brenkao is testing the package #185

brenkao is testing the package

brenkao is testing the package #185

Workflow file for this run

name: tests
run-name: ${{ github.actor }} is testing the package
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
tests:
name: Tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12"]
steps:
- uses: actions/checkout@v3
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: 9
run_install: false
- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: "pnpm"
cache-dependency-path: "./client/pnpm-lock.yaml"
- name: Install dependencies
working-directory: ./client
run: pnpm install
- name: Build client
working-directory: ./client
run: pnpm run build:notypescript
- name: Set up uv
run: curl -LsSf https://astral.sh/uv/0.4.4/install.sh | sh
- name: Set up Python ${{ matrix.python-version }}
run: |
uv python install ${{ matrix.python-version }}
echo "${{ matrix.python-version }}" > .python-version
- name: Restore uv cache
uses: actions/cache@v4
with:
path: /tmp/.uv-cache
key: uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
restore-keys: |
uv-${{ runner.os }}-${{ hashFiles('uv.lock') }}
uv-${{ runner.os }}
- name: Install the project
run: uv sync --all-extras --dev
- name: Run Tests
run: uv run pytest tests/ --cov=./ --cov-report=xml
- name: Minimize uv cache
run: uv cache prune --ci