Skip to content

Commit 69fa479

Browse files
committed
Test on Python 3.13
1 parent 9fe3560 commit 69fa479

File tree

7 files changed

+34
-8
lines changed

7 files changed

+34
-8
lines changed

.github/workflows/python_ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
runs-on: "windows-2019"
2323
continue-on-error: ${{ matrix.config.experimental }}
2424
env:
25-
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,pypy-3.7,pypy-3.8,pypy-3.9'
25+
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,3.13,pypy-3.7,pypy-3.8,pypy-3.9'
2626

2727
strategy:
2828
fail-fast: False
@@ -34,6 +34,7 @@ jobs:
3434
- {python-version: "3.10", testenvs: "py310,build", experimental: False}
3535
- {python-version: "3.11", testenvs: "py311,build", experimental: False}
3636
- {python-version: "3.12", testenvs: "py312,build", experimental: False}
37+
- {python-version: "3.13", testenvs: "py313,build", experimental: False}
3738
- {python-version: "pypy-3.7", testenvs: "pypy37,build", experimental: False}
3839
- {python-version: "pypy-3.8", testenvs: "pypy38,build", experimental: False}
3940
- {python-version: "pypy-3.9-v7.3.15", testenvs: "pypy39,build", experimental: True}

.github/workflows/python_ci_linux.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
runs-on: "ubuntu-22.04"
2424
continue-on-error: ${{ matrix.config.experimental }}
2525
env:
26-
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,pypy-3.7,pypy-3.8,pypy-3.9'
26+
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,3.13,pypy-3.7,pypy-3.8,pypy-3.9'
2727

2828
strategy:
2929
fail-fast: False
@@ -35,6 +35,7 @@ jobs:
3535
- {python-version: "3.10", testenvs: "py310,build", experimental: False}
3636
- {python-version: "3.11", testenvs: "py311,build", experimental: False}
3737
- {python-version: "3.12", testenvs: "py312,build", experimental: False}
38+
- {python-version: "3.13", testenvs: "py313,build", experimental: False}
3839
- {python-version: "pypy-3.7", testenvs: "pypy37,build", experimental: False}
3940
- {python-version: "pypy-3.8", testenvs: "pypy38,build", experimental: False}
4041
- {python-version: "pypy-3.9", testenvs: "pypy39,build", experimental: True}

.github/workflows/python_ci_macos.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
runs-on: "macos-${{ matrix.config.os-ver }}"
2323
continue-on-error: ${{ matrix.config.experimental }}
2424
env:
25-
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,pypy-3.7,pypy-3.8,pypy-3.9'
25+
USING_COVERAGE: '3.7,3.8,3.9,3.10,3.11,3.12,3.13,pypy-3.7,pypy-3.8,pypy-3.9'
2626

2727
strategy:
2828
fail-fast: False
@@ -34,6 +34,7 @@ jobs:
3434
- {python-version: "3.10", os-ver: "14", testenvs: "py310,build", experimental: False}
3535
- {python-version: "3.11", os-ver: "14", testenvs: "py311,build", experimental: False}
3636
- {python-version: "3.12", os-ver: "14", testenvs: "py312,build", experimental: False}
37+
- {python-version: "3.13", os-ver: "14", testenvs: "py313,build", experimental: False}
3738
- {python-version: "pypy-3.7", os-ver: "13", testenvs: "pypy37,build", experimental: False}
3839
- {python-version: "pypy-3.8", os-ver: "14", testenvs: "pypy38,build", experimental: False}
3940
- {python-version: "pypy-3.9", os-ver: "14", testenvs: "pypy39,build", experimental: True}

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ base-classifiers = [
3131
"Topic :: Utilities",
3232
"Typing :: Typed",
3333
]
34-
python-versions = [ "3.7", "3.8", "3.9", "3.10", "3.11", "3.12",]
34+
python-versions = [ "3.7", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13",]
3535
python-implementations = [ "CPython", "PyPy",]
3636
platforms = [ "Windows", "macOS", "Linux",]
3737
license-key = "MIT"

repo_helper.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ python_versions:
2424
- "3.10"
2525
- "3.11"
2626
- "3.12"
27+
- "3.13"
2728
- "pypy37"
2829
- "pypy38"
2930
- "pypy39"

tests/stdlib_tests/test_fail.py

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
# 3rd party
66
import pytest
7+
from coincidence.selectors import max_version, min_version
78
from domdf_python_tools.compat import PYPY
89

910
# this package
@@ -162,11 +163,18 @@ def test_truncated_input(data: str, msg: str, idx: int):
162163
('{"spam":[}', unexpected_right_brace, 9),
163164
("[42:", unexpected_colon, 3),
164165
('[42 "spam"', "Unexpected '\"' when decoding array" if PYPY else "Expecting ',' delimiter", 4),
165-
("[42,]", "Unexpected ']'" if PYPY else "Expecting value", 4),
166+
pytest.param("[42,]", "Illegal trailing comma before end of array", 3, marks=min_version((3, 13))),
167+
pytest.param(
168+
"[42,]", "Unexpected ']'" if PYPY else "Expecting value", 4, marks=max_version((3, 12))
169+
),
166170
('{"spam":[42}', "Unexpected '}' when decoding array" if PYPY else "Expecting ',' delimiter", 11),
167171
('["]', "Unterminated string starting at", 1),
168172
('["spam":', unexpected_colon, 7),
169-
('["spam",]', "Unexpected ']'" if PYPY else "Expecting value", 8),
173+
pytest.param(
174+
'["spam",]', "Illegal trailing comma before end of array", 7, marks=min_version((3, 13))
175+
),
176+
pytest.
177+
param('["spam",]', "Unexpected ']'" if PYPY else "Expecting value", 8, marks=max_version((3, 12))),
170178
("{:", property_name_string, 1),
171179
("{,", property_name_string, 1),
172180
("{42", property_name_string, 1),
@@ -182,7 +190,13 @@ def test_truncated_input(data: str, msg: str, idx: int):
182190
11
183191
),
184192
('[{"spam":42]', "Unexpected ']' when decoding object" if PYPY else "Expecting ',' delimiter", 11),
185-
('{"spam":42,}', property_name_string, 11),
193+
pytest.param(
194+
'{"spam":42,}',
195+
"Illegal trailing comma before end of object",
196+
10,
197+
marks=min_version((3, 13))
198+
),
199+
pytest.param('{"spam":42,}', property_name_string, 11, marks=max_version((3, 12))),
186200
]
187201
)
188202
def test_unexpected_data(data: str, msg: str, idx: int):

tox.ini

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ envlist =
2828
py310
2929
py311
3030
py312
31+
py313
3132
pypy37
3233
pypy38
3334
pypy39
@@ -42,7 +43,7 @@ requires =
4243
virtualenv!=20.16.0
4344

4445
[envlists]
45-
test = py37, py38, py39, py310, py311, py312, pypy37, pypy38, pypy39
46+
test = py37, py38, py39, py310, py311, py312, py313, pypy37, pypy38, pypy39
4647
qa = mypy, lint
4748
cov = py38, coverage
4849

@@ -61,6 +62,13 @@ setenv =
6162
PYTHONDEVMODE=1
6263
PIP_DISABLE_PIP_VERSION_CHECK=1
6364

65+
[testenv:py313]
66+
download = True
67+
setenv =
68+
PYTHONDEVMODE=1
69+
PIP_DISABLE_PIP_VERSION_CHECK=1
70+
UNSAFE_PYO3_SKIP_VERSION_CHECK=1
71+
6472
[testenv:py312]
6573
download = True
6674
setenv =

0 commit comments

Comments
 (0)