Skip to content

update

update #38

Workflow file for this run

name: CI
on: [push, pull_request]
jobs:
build:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
name: [
Python 3.13 (Macintosh),
Python 3.13 (Ubuntu),
Python 3.12 (Macintosh),
Python 3.12 (Ubuntu),
Python 3.11 (Macintosh),
Python 3.11 (Ubuntu),
Python 3.10 (Macintosh),
Python 3.10 (Ubuntu),
]
include:
- name: Python 3.13 (Macintosh)
os: macos-latest
python-version: '3.13'
- name: Python 3.13 (Ubuntu)
os: ubuntu-latest
python-version: '3.13'
- name: Python 3.12 (Macintosh)
os: macos-latest
python-version: '3.12'
- name: Python 3.12 (Ubuntu)
os: ubuntu-latest
python-version: '3.12'
- name: Python 3.11 (Macintosh)
os: macos-latest
python-version: '3.11'
- name: Python 3.11 (Ubuntu)
os: ubuntu-latest
python-version: '3.11'
- name: Python 3.10 (Macintosh)
os: macos-latest
python-version: '3.10'
- name: Python 3.10 (Ubuntu)
os: ubuntu-latest
python-version: '3.10'
env:
VENV_DIR: env
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: "Caching (for Linux)"
uses: actions/cache@v4
if: startsWith(runner.os, 'linux')
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: ${{ runner.os }}-pip-
- name: "Caching (for Macintosh)"
uses: actions/cache@v4
if: startsWith(runner.os, 'macos')
with:
path: ~/Library/Caches/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: ${{ runner.os }}-pip-
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Initialize environment
shell: bash
run: python -m venv "${VENV_DIR}"
- name: Install packages
shell: bash
run: |
case "${{ matrix.os }}" in
windows*) scripts="Scripts";;
* ) scripts="bin";;
esac
. "${VENV_DIR}/${scripts}/activate"
python -m pip install --default-timeout=1000 -r requirements.txt
- name: Run tests
shell: bash
run: |
case "${{ matrix.os }}" in
windows*) scripts="Scripts";;
* ) scripts="bin";;
esac
. "${VENV_DIR}/${scripts}/activate"
echo "Using $(python --version) on ${{ matrix.os }}" 1>&2
nosetests --with-coverage tests