2023-07-09 15:59:27 +01:00
|
|
|
pr:
|
|
|
|
|
paths:
|
|
|
|
|
exclude:
|
2025-06-10 17:57:25 -04:00
|
|
|
- .github/**
|
|
|
|
|
- bin/*
|
|
|
|
|
- docs/**
|
|
|
|
|
- examples/github-*
|
|
|
|
|
- examples/ci*
|
|
|
|
|
- examples/travis-ci-*
|
|
|
|
|
- .ci*
|
2023-07-10 11:34:10 +01:00
|
|
|
- .pre-commit-config.yaml
|
2025-06-10 17:57:25 -04:00
|
|
|
- .readthedocs.yml
|
|
|
|
|
- .travis.yml
|
|
|
|
|
- README.md
|
2026-07-24 14:55:37 -04:00
|
|
|
- properdocs.yml
|
2025-06-10 17:57:25 -04:00
|
|
|
- noxfile.py
|
2023-07-09 15:59:27 +01:00
|
|
|
|
2019-03-10 22:50:07 +00:00
|
|
|
jobs:
|
2025-08-13 08:52:27 -04:00
|
|
|
- job: tests
|
|
|
|
|
strategy:
|
|
|
|
|
matrix:
|
2026-06-05 08:09:16 -04:00
|
|
|
linux_313:
|
2025-08-13 08:52:27 -04:00
|
|
|
imageName: "ubuntu-latest"
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "native"
|
2026-06-05 08:09:16 -04:00
|
|
|
android_313:
|
2025-08-13 08:52:27 -04:00
|
|
|
imageName: "ubuntu-latest"
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "android"
|
2026-06-05 08:09:16 -04:00
|
|
|
macos_313:
|
2025-08-13 08:52:27 -04:00
|
|
|
imageName: "macos-latest"
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "native"
|
2026-06-05 08:09:16 -04:00
|
|
|
ios_313:
|
2025-08-21 07:51:06 +08:00
|
|
|
imageName: "macos-14" # See https://github.com/actions/runner-images/issues/12777
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "ios"
|
2026-06-05 08:09:16 -04:00
|
|
|
android_macos_313:
|
2025-08-13 08:52:27 -04:00
|
|
|
imageName: "macos-latest"
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "android"
|
2026-06-05 08:09:16 -04:00
|
|
|
windows_313:
|
2025-08-13 08:52:27 -04:00
|
|
|
imageName: "windows-latest"
|
2026-06-05 08:09:16 -04:00
|
|
|
pythonVersion: "3.13"
|
2025-08-13 08:52:27 -04:00
|
|
|
testSelect: "native"
|
2025-04-29 00:25:17 +02:00
|
|
|
timeoutInMinutes: 180
|
2025-08-13 08:52:27 -04:00
|
|
|
pool:
|
|
|
|
|
vmImage: $(imageName)
|
2026-06-05 08:09:16 -04:00
|
|
|
variables:
|
|
|
|
|
# Relocate cibuildwheel's download cache (interpreters) and the per-worker
|
|
|
|
|
# test pip caches (which live under it) to a stable, cacheable path.
|
|
|
|
|
CIBW_CACHE_PATH: $(Pipeline.Workspace)/.cibw-cache
|
2025-08-13 08:52:27 -04:00
|
|
|
|
2019-10-26 01:09:19 +02:00
|
|
|
steps:
|
2019-03-10 22:50:07 +00:00
|
|
|
- task: UsePythonVersion@0
|
2019-11-09 11:19:02 +01:00
|
|
|
inputs:
|
2025-08-13 08:52:27 -04:00
|
|
|
versionSpec: $(pythonVersion)
|
|
|
|
|
|
2026-06-05 08:09:16 -04:00
|
|
|
- task: Cache@2
|
|
|
|
|
displayName: 'Cache cibuildwheel downloads'
|
|
|
|
|
inputs:
|
|
|
|
|
# build-platforms.toml carries the interpreter pins; bump the version
|
|
|
|
|
# prefix to force a cold cache. restoreKeys lets a stale cache still seed
|
|
|
|
|
# a new run (cibuildwheel re-downloads only what's missing).
|
|
|
|
|
key: 'cibw-cache | v1 | "$(imageName)" | "$(testSelect)" | cibuildwheel/resources/build-platforms.toml'
|
|
|
|
|
restoreKeys: |
|
|
|
|
|
cibw-cache | v1 | "$(imageName)" | "$(testSelect)"
|
|
|
|
|
path: $(CIBW_CACHE_PATH)
|
|
|
|
|
|
2025-07-23 22:18:33 +01:00
|
|
|
- task: JavaToolInstaller@0
|
2025-08-13 08:52:27 -04:00
|
|
|
condition: and(eq(variables['testSelect'], 'android'), eq(variables['Agent.OS'], 'Linux'))
|
2025-07-23 22:18:33 +01:00
|
|
|
inputs:
|
|
|
|
|
versionSpec: '17'
|
|
|
|
|
jdkArchitectureOption: 'x64'
|
|
|
|
|
jdkSourceOption: 'PreInstalled'
|
2019-03-10 22:50:07 +00:00
|
|
|
|
2025-08-13 08:52:27 -04:00
|
|
|
- bash: docker run --rm --privileged docker.io/tonistiigi/binfmt:latest --install all
|
|
|
|
|
condition: and(eq(variables['imageName'], 'ubuntu-latest'), eq(variables['testSelect'], 'native'))
|
|
|
|
|
displayName: 'Install binfmt on Linux'
|
|
|
|
|
|
|
|
|
|
- bash: python -m pip install -U pip && python -m pip install -e. --group test
|
|
|
|
|
displayName: 'Update pip and install cibuildwheel --group test'
|
|
|
|
|
|
|
|
|
|
- bash: echo "##vso[task.setvariable variable=CIBW_ENABLE;]all"
|
|
|
|
|
condition: eq(variables['Build.SourceBranch'], 'refs/heads/main')
|
|
|
|
|
displayName: Set CIBW_ENABLE to all (main branch)
|
2019-03-10 22:50:07 +00:00
|
|
|
|
|
|
|
|
- bash: |
|
2025-08-13 08:52:27 -04:00
|
|
|
echo "CIBW_ENABLE = $CIBW_ENABLE"
|
|
|
|
|
python ./bin/run_tests.py --test-select $(testSelect)
|
|
|
|
|
displayName: 'Run tests'
|