Repository navigation
60 lines (60 loc) · 2.09 KB
/
Copy pathci.yml
File metadata and controls
60 lines (60 loc) · 2.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: CI
on:
push:
pull_request:
schedule:
# Weekly, so a new Python release is tested even without a push.
- cron: '0 6 * * 1'
permissions:
contents: read
jobs:
test:
name: test (${{ matrix.os }}, ${{ matrix.python-version }})
runs-on: ${{ matrix.os }}
# Pre-releases of the next Python version warn early but do not block.
continue-on-error: ${{ matrix.prerelease == true }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
# Every released Python version from 3.10 on. Add each new release here.
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15"]
include:
# "3.x" is always the newest stable release, so a new Python version
# is tested on every platform as soon as GitHub Actions offers it.
- os: ubuntu-latest
python-version: "3.x"
- os: windows-latest
python-version: "3.x"
- os: macos-latest
python-version: "3.x"
# Next Python version while it is in alpha, beta or release candidate.
# Raise it by one after each final release.
- os: ubuntu-latest
python-version: "3.16"
prerelease: true
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: ${{ matrix.prerelease == true }}
- name: Install ffmpeg (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends ffmpeg
- name: Install ffmpeg (macOS)
if: runner.os == 'macOS'
run: brew install ffmpeg
- name: Install ffmpeg (Windows)
if: runner.os == 'Windows'
run: choco install ffmpeg -y --no-progress
- name: Install package and test tools
run: python -m pip install -e . pytest pytest-mock
- name: Test
run: |
python --version
ffmpeg -version
python -m pytest -q