Skip to content

Test

Test #40749

Workflow file for this run

name: Test
permissions: {}
on:
schedule:
- cron: '47 * * * *'
pull_request:
push:
branches:
- '[0-9].[0-9].x'
tags:
- '*'
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
# The number of builds that submit code coverage configured here MUST be identical
# to the number of `after_n_builds` in ./codecov.yml.
- name: 'Python 3.14'
os: ubuntu-latest
nodejs: 25.x
python: '3.14'
- name: 'Python 3.13'
os: ubuntu-latest
nodejs: 25.x
python: '3.13'
- name: 'macOS'
os: macos-latest
nodejs: 25.x
python: '3.14'
- name: 'Windows'
os: windows-latest
nodejs: 25.x
python: '3.14'
timeout-minutes: 60
steps:
- name: Check out the source code
uses: actions/checkout@v6
- name: Get the pip cache directory
run: echo "pip_cache_dir=$(pip cache dir)" >> $GITHUB_ENV
shell: bash
- name: Cache pip
uses: actions/cache@v5
with:
path: ${{ env.pip_cache_dir }}
key: pip-${{ runner.os }}-${{ matrix.python }}-${{ hashFiles('./pyproject.toml') }}
restore-keys: |
pip-${{ runner.os }}-${{ matrix.python }}-
- name: Get the npm cache directory
run: echo "npm_cache_dir=$(npm config get cache)" >> $GITHUB_ENV
shell: bash
- name: Cache npm
uses: actions/cache@v5
with:
path: ${{ env.npm_cache_dir }}
key: npm-${{ runner.os }}-${{ hashFiles('./package.json') }}
restore-keys: |
npm-${{ runner.os }}-
- name: Set up Python ${{ matrix.python }}
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python }}
- name: Set up Node.js
uses: actions/setup-node@v6
with:
node-version: ${{ matrix.nodejs }}
- name: Install APT dependencies
if: startsWith(runner.os, 'Linux')
run: |
sudo apt-get update
sudo apt-get install poppler-utils
- name: Install Brew dependencies
if: startsWith(runner.os, 'macOS')
run: brew install poppler
- name: Install Scoop dependencies
if: startsWith(runner.os, 'Windows')
uses: MinoruSekine/setup-scoop@v4
with:
apps: poppler
- name: Build the development environment
run: |
source '.github/workflows/test-${{ matrix.name }}.sh'
./bin/build-ci.py
shell: bash
- name: Run the tests
run: |
source '.github/workflows/test-${{ matrix.name }}.sh'
./bin/test.py
shell: bash
- name: Upload code coverage
uses: codecov/codecov-action@v6
with:
token: ${{ secrets.CODECOV_TOKEN }}