|
33 | 33 | ISORT_VERSION = "isort==5.11.0" |
34 | 34 | LINT_PATHS = ["docs", "google", "tests", "noxfile.py", "setup.py"] |
35 | 35 |
|
36 | | -DEFAULT_PYTHON_VERSION = "3.8" |
| 36 | +DEFAULT_PYTHON_VERSION = "3.13" |
37 | 37 |
|
38 | 38 | UNIT_TEST_PYTHON_VERSIONS: List[str] = [ |
39 | 39 | "3.7", |
|
61 | 61 | UNIT_TEST_EXTRAS: List[str] = [] |
62 | 62 | UNIT_TEST_EXTRAS_BY_PYTHON: Dict[str, List[str]] = {} |
63 | 63 |
|
64 | | -SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.7"] |
| 64 | +SYSTEM_TEST_PYTHON_VERSIONS: List[str] = ["3.9"] |
65 | 65 | SYSTEM_TEST_STANDARD_DEPENDENCIES: List[str] = [ |
66 | 66 | "mock", |
67 | 67 | "pytest", |
|
79 | 79 | CURRENT_DIRECTORY = pathlib.Path(__file__).parent.absolute() |
80 | 80 |
|
81 | 81 | nox.options.sessions = [ |
82 | | - "unit", |
| 82 | + "unit-3.9", |
| 83 | + "unit-3.10", |
| 84 | + "unit-3.11", |
| 85 | + "unit-3.12", |
| 86 | + "unit-3.13", |
83 | 87 | "system_emulated", |
84 | 88 | "system", |
85 | 89 | "mypy", |
@@ -170,7 +174,7 @@ def mypy(session): |
170 | 174 | @nox.session(python=DEFAULT_PYTHON_VERSION) |
171 | 175 | def lint_setup_py(session): |
172 | 176 | """Verify that setup.py is valid (including RST check).""" |
173 | | - session.install("docutils", "pygments") |
| 177 | + session.install("setuptools", "docutils", "pygments") |
174 | 178 | session.run("python", "setup.py", "check", "--restructuredtext", "--strict") |
175 | 179 |
|
176 | 180 |
|
@@ -210,7 +214,8 @@ def install_unittest_dependencies(session, *constraints): |
210 | 214 | def unit(session, protobuf_implementation): |
211 | 215 | # Install all test dependencies, then install this package in-place. |
212 | 216 |
|
213 | | - if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"): |
| 217 | + py_version = tuple([int(v) for v in session.python.split(".")]) |
| 218 | + if protobuf_implementation == "cpp" and py_version >= (3, 11): |
214 | 219 | session.skip("cpp implementation is not supported in python 3.11+") |
215 | 220 |
|
216 | 221 | constraints_path = str( |
@@ -469,7 +474,8 @@ def docfx(session): |
469 | 474 | def prerelease_deps(session, protobuf_implementation): |
470 | 475 | """Run all tests with prerelease versions of dependencies installed.""" |
471 | 476 |
|
472 | | - if protobuf_implementation == "cpp" and session.python in ("3.11", "3.12", "3.13"): |
| 477 | + py_version = tuple([int(v) for v in session.python.split(".")]) |
| 478 | + if protobuf_implementation == "cpp" and py_version >= (3, 11): |
473 | 479 | session.skip("cpp implementation is not supported in python 3.11+") |
474 | 480 |
|
475 | 481 | # Install all dependencies |
|
0 commit comments