Skip to content

Commit

Permalink
feat: support testing with python 3.11
Browse files Browse the repository at this point in the history
  • Loading branch information
EspenAlbert committed Aug 20, 2023
1 parent 1ed875e commit 139d790
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 4 deletions.
1 change: 1 addition & 0 deletions _pants/py_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ def py_package(
classifiers=[
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
],
extras_require=extras_require or {},
long_description_content_type="text/markdown",
Expand Down
1 change: 1 addition & 0 deletions _pants/py_test_versions.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
test_versions = parametrize(py39=["==3.9.*"], py310=["==3.10.*"], py311=["==3.11.*"])
2 changes: 1 addition & 1 deletion compose_chart_export/tests/test_chart_export/BUILD
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
resources(name="reg", sources=["charts/*", "compose_files/*"])
python_tests(
dependencies=[":reg"],
interpreter_constraints=parametrize(py39=["==3.9.*"], py310=["==3.10.*"]),
interpreter_constraints=test_versions,
)
2 changes: 1 addition & 1 deletion model_lib/test/test_model_lib/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ resources(name="json", sources=["test_dump_functions/*.json"])
python_test_utils(name="conftest", resolve=parametrize("python-default", "pydantic-v1"))
python_tests(
dependencies=[":json"],
interpreter_constraints=parametrize(py39=["==3.9.*"], py310=["==3.10.*"]),
interpreter_constraints=test_versions,
# resolve=parametrize("python-default", "pydantic-v1")
)
2 changes: 1 addition & 1 deletion pants.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
pants_version = "2.17.0rc3"
print_stacktrace = true
level = "warn"
build_file_prelude_globs = ["_pants/py_deploy.py", "_pants/py_package.py"]
build_file_prelude_globs = ["_pants/*.py"]

# for plugin development
pythonpath = ["%(buildroot)s/_pants/pants_py_deploy/src", "%(buildroot)s/compose_chart_export/src", "%(buildroot)s/docker_compose_parser/src", "%(buildroot)s/model_lib/src", "%(buildroot)s/zero_3rdparty/src"]
Expand Down
2 changes: 1 addition & 1 deletion zero_3rdparty/tests/test_zero_3rdparty/BUILD
Original file line number Diff line number Diff line change
@@ -1 +1 @@
python_tests(interpreter_constraints=parametrize(py39=["==3.9.*"], py310=["==3.10.*"]))
python_tests(interpreter_constraints=test_versions)

0 comments on commit 139d790

Please sign in to comment.