Skip to content

Commit ac8f1b3

Browse files
committed
Removed tox and simplified test workflow.
1 parent 35fb223 commit ac8f1b3

File tree

3 files changed

+52
-95
lines changed

3 files changed

+52
-95
lines changed

.github/workflows/build.yml

Lines changed: 49 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -1,80 +1,57 @@
11
name: Build
22

33
on:
4-
push:
5-
branches:
6-
- master
7-
pull_request:
8-
branches:
9-
- master
4+
push:
5+
branches:
6+
- master
7+
pull_request:
8+
branches:
9+
- master
1010

11-
jobs:
12-
test:
13-
name: "${{ matrix.os }}: ${{ matrix.tox-env }}"
14-
runs-on: ${{ matrix.os }}
15-
strategy:
16-
fail-fast: false
17-
matrix:
18-
tox-env:
19-
[
20-
py39-test,
21-
py310-test,
22-
py311-test,
23-
py312-test,
24-
py313-test,
25-
pypy-test,
26-
]
27-
os: [ubuntu-24.04, windows-latest]
11+
env:
12+
MAIN_PYTHON_VERSION: "3.12"
2813

29-
# Only test on a couple of versions on Windows.
30-
exclude:
31-
- os: windows-latest
32-
tox-env: pypy-test
14+
jobs:
15+
test:
16+
name: "${{ matrix.os }}: ${{ matrix.python-version }}"
17+
runs-on: ${{ matrix.os }}
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
22+
os: [ubuntu-24.04, windows-latest]
3323

34-
# Python interpreter versions. :/
35-
include:
36-
- tox-env: py39-test
37-
python: "3.9"
38-
- tox-env: py310-test
39-
python: "3.10"
40-
- tox-env: py311-test
41-
python: "3.11"
42-
- tox-env: py312-test
43-
python: "3.12"
44-
- tox-env: py313-test
45-
python: "3.13"
46-
- tox-env: pypy-test
47-
python: pypy3.9
24+
steps:
25+
- uses: actions/checkout@v5
26+
- name: Set up Python ${{ matrix.python-version }}
27+
uses: actions/setup-python@v5
28+
with:
29+
python-version: ${{ matrix.python-version }}
30+
- name: Install dependencies
31+
run: |
32+
python -m pip install --upgrade pip
33+
pip install .[dev]
4834
49-
steps:
50-
- uses: actions/checkout@v3
51-
- name: Set up Python ${{ matrix.python }}
52-
uses: actions/setup-python@v4
53-
with:
54-
python-version: ${{ matrix.python }}
55-
- name: Install Tox
56-
run: pip install tox
57-
- name: Tox
58-
run: tox -e ${{ matrix.tox-env }}
35+
- name: Run tests
36+
run: |
37+
pytest -v --cov=mediafile --cov-report=xml tests/
5938
60-
style:
61-
name: Style
62-
runs-on: ubuntu-latest
63-
steps:
64-
- uses: actions/checkout@v4
65-
- name: Install Python
66-
uses: actions/setup-python@v5
67-
with:
68-
python-version: "3.9"
69-
- name: Install dependencies
70-
run: |
71-
python -m pip install --upgrade pip
72-
pip install .[dev]
73-
- name: Check style with Ruff
74-
id: ruff
75-
run: |
76-
ruff check --output-format=github .
77-
- name: Check format with Ruff
78-
id: ruff-format
79-
run: |
80-
ruff format --check .
39+
style:
40+
name: Style
41+
runs-on: ubuntu-latest
42+
steps:
43+
- uses: actions/checkout@v5
44+
- name: Set up Python ${{ env.MAIN_PYTHON_VERSION }}
45+
uses: actions/setup-python@v5
46+
with:
47+
python-version: ${{ env.MAIN_PYTHON_VERSION }}
48+
- name: Install dependencies
49+
run: |
50+
python -m pip install --upgrade pip
51+
pip install .[dev]
52+
- name: Check style with Ruff
53+
run: |
54+
ruff check --output-format=github .
55+
- name: Check format with Ruff
56+
run: |
57+
ruff format --check .

pyproject.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,11 @@ dynamic = ["version"]
1515
classifiers = [
1616
'Topic :: Multimedia :: Sound/Audio',
1717
'Environment :: Web Environment',
18-
'Programming Language :: Python :: 3.7',
19-
'Programming Language :: Python :: 3.8',
2018
'Programming Language :: Python :: 3.9',
2119
'Programming Language :: Python :: 3.10',
20+
'Programming Language :: Python :: 3.11',
21+
'Programming Language :: Python :: 3.12',
22+
'Programming Language :: Python :: 3.13',
2223
'Programming Language :: Python :: Implementation :: PyPy',
2324
]
2425
dependencies = [

tox.ini

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)