Compare commits

...

11 Commits

Author SHA1 Message Date
Miro Hrončok 62ab817d28 Update to 4.26.0
- Requires virtualenv 20.29+
- Supports freethreading Python
- Fixes: rhbz#2365939

This drops support for Python 3.8.
I don't know if that means running 3.8 venvs, or just running on 3.8,
but I dropped all the 3.8 bits, as this update is targeted to Fedora 42+ only anyway.
2025-05-13 22:19:54 +02:00
Miro Hrončok fa857a3318 Without wheel, test_result_json_sequential fetches it from the internet
[skip changelog]
2025-05-13 19:41:39 +02:00
Miro Hrončok afb013056b Don't skip some tests twice
We already skip those regardless of %bcond ci_tests.

[skip changelog]
2025-05-13 17:28:17 +02:00
Miro Hrončok 2d52eab0d1 Run more tests with setuptools 70.1+
But keep test_result_json_sequential skipped with bundled wheel.

[skip changelog]
2025-05-13 17:28:17 +02:00
Miro Hrončok 6b3221eebd Fix tests with virtualenv 20.31+ 2025-05-13 17:28:17 +02:00
Karolina Surma 17cf20500b Support Python 3.14.0b1 2025-05-12 18:03:59 +02:00
Miro Hrončok 104f6b73e2 Setup rpmlint filters
[skip changelog]
2025-03-28 17:01:26 +01:00
Miro Hrončok 453dfdb9aa CI: Make the tests pass on EPEL 10, install or skip missing Pythons
[skip changelog]
2025-03-28 15:43:28 +01:00
Tomáš Hrnčiar eeb73bfe13 CI: Test with pypy3.11, make pypy3.9 optional, as it was retired on Fedora 42+ 2025-03-28 12:38:54 +01:00
Tomáš Hrnčiar 0464e297ad Update to 4.25.0
Fixes: rhbz#2350693
2025-03-28 10:10:38 +01:00
Miro Hrončok 07d47763fe Python 3.14.0a6+ test fix
- Fixes: rhbz#2353145
2025-03-18 13:02:59 +01:00
5 changed files with 57 additions and 47 deletions
+19 -17
View File
@@ -1,11 +1,12 @@
From 156ff454c8df051b2cb3a6b5283810c51c1d5853 Mon Sep 17 00:00:00 2001
From: Lumir Balhar <lbalhar@redhat.com>
Date: Tue, 10 Jan 2023 08:34:25 +0100
From 924b03e0446561bbfca9679a44642a1a96dd8f10 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Hrn=C4=8Diar?= <thrnciar@redhat.com>
Date: Fri, 28 Mar 2025 09:44:24 +0100
Subject: [PATCH] Fix tests
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Co-Authored-By: Lumir Balhar <lbalhar@redhat.com>
Co-Authored-By: Miro Hrončok <miro@hroncok.cz>
---
pyproject.toml | 11 +----------
@@ -15,7 +16,7 @@ Co-Authored-By: Miro Hrončok <miro@hroncok.cz>
4 files changed, 14 insertions(+), 41 deletions(-)
diff --git a/pyproject.toml b/pyproject.toml
index 16f2e44..156d1af 100644
index 9b52c2f..335012b 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -82,22 +82,16 @@ dev = [
@@ -29,18 +30,18 @@ index 16f2e44..156d1af 100644
"distlib>=0.3.9",
"flaky>=3.8.1",
"hatch-vcs>=0.4",
"hatchling>=1.26.3",
"psutil>=6.1",
"pytest>=8.3.3",
"hatchling>=1.27",
"psutil>=6.1.1",
"pytest>=8.3.4",
- "pytest-cov>=5",
"pytest-mock>=3.14",
"pytest-xdist>=3.6.1",
"re-assert>=1.1",
- "setuptools>=75.1; python_version<='3.8'",
- "setuptools>=75.6; python_version>'3.8'",
- "setuptools>=75.3; python_version<='3.8'",
- "setuptools>=75.8; python_version>'3.8'",
+ "setuptools>=75.1",
"time-machine>=2.15; implementation_name!='pypy'",
"wheel>=0.45",
"wheel>=0.45.1",
]
@@ -223,9 +217,6 @@ report.omit = [
"tests/type_check/*",
@@ -53,7 +54,7 @@ index 16f2e44..156d1af 100644
[tool.towncrier]
name = "tox"
diff --git a/src/tox/pytest.py b/src/tox/pytest.py
index 72f410b..48cf9bc 100644
index bca2ad8..973e714 100644
--- a/src/tox/pytest.py
+++ b/src/tox/pytest.py
@@ -17,7 +17,6 @@ from typing import TYPE_CHECKING, Any, Callable, Iterator, Protocol, Sequence, c
@@ -64,20 +65,21 @@ index 72f410b..48cf9bc 100644
from virtualenv.info import fs_supports_symlink
import tox.run
@@ -280,9 +279,9 @@ class ToxProject:
@@ -280,10 +279,10 @@ class ToxProject:
m.setattr(sys, "argv", [sys.executable, "-m", "tox", *list(args)])
m.setenv("VIRTUALENV_SYMLINK_APP_DATA", "1")
m.setenv("VIRTUALENV_SYMLINKS", "1")
- m.setenv("VIRTUALENV_PIP", "embed")
- m.setenv("VIRTUALENV_WHEEL", "embed")
- m.setenv("VIRTUALENV_SETUPTOOLS", "embed")
+ m.setenv("VIRTUALENV_PIP", "bundle")
+ m.setenv("VIRTUALENV_WHEEL", "bundle")
if sys.version_info[:2] < (3, 9):
- m.setenv("VIRTUALENV_WHEEL", "embed")
- m.setenv("VIRTUALENV_SETUPTOOLS", "embed")
+ m.setenv("VIRTUALENV_WHEEL", "bundle")
+ m.setenv("VIRTUALENV_SETUPTOOLS", "bundle")
try:
tox_run(args)
except SystemExit as exception:
@@ -475,15 +474,6 @@ def enable_pypi_server(monkeypatch: pytest.MonkeyPatch, url: str | None) -> None
@@ -476,15 +475,6 @@ def enable_pypi_server(monkeypatch: pytest.MonkeyPatch, url: str | None) -> None
monkeypatch.setenv("PIP_TIMEOUT", str(2))
@@ -161,5 +163,5 @@ index efb5b12..8a57426 100644
for left, right in zip_longest(result, exp):
assert isinstance(right, Requirement)
--
2.47.1
2.49.0
+15 -9
View File
@@ -20,7 +20,7 @@
%undefine _py3_shebang_s
Name: python-tox
Version: 4.24.1
Version: 4.26.0
Release: %autorelease
Summary: Virtualenv-based automation of test activities
@@ -83,9 +83,6 @@ Summary: %{summary}
# It recommends all Python versions it supports. (This is an exception to
# the rule that Fedora packages may not require the alternative interpreters.)
%if 0%{?fedora}
%if 0%{?fedora} < 42
Recommends: python3.8
%endif
Recommends: python3.9
Recommends: python3.10
Recommends: pypy3-devel
@@ -106,7 +103,7 @@ Recommends: python3-devel
# see https://github.com/tox-dev/tox/pull/2843#discussion_r1065028356
sed -ri -e 's/"(packaging|filelock|platformdirs|psutil|pyproject-api|pytest|pytest-mock|pytest-xdist|wheel|pluggy|distlib|cachetools|build\[virtualenv\]|setuptools|flaky)>=.*/"\1",/g' \
-e 's/"(time-machine)>=[^;"]+/"\1/' \
-e 's/"(virtualenv)>=.*/"\1>=20",/g' \
-e 's/"(virtualenv)>=.*/"\1>=20.29",/g' \
-e 's/"(hatchling)>=.*/"\1>=1.13",/g' \
pyproject.toml
@@ -127,6 +124,12 @@ export SETUPTOOLS_SCM_PRETEND_VERSION="%{version}"
%if %{with tests}
%check
# Upstream requires virtualenv >= 20.31 for tests, and no longer sets VIRTUALENV_WHEEL.
# To support environments with older virtualenv, we set it manually:
%if v"%(%{python3} -c 'import importlib.metadata as im; print(im.version("virtualenv"))' 2>/dev/null || echo 0)" < v"20.31"
export VIRTUALENV_WHEEL=bundle
%endif
# Skipped tests use internal virtualenv functionality to
# download wheels which does not work with "bundled" version of wheel in
# the Fedora's virtualenv patch.
@@ -140,23 +143,26 @@ k="${k-}${k+ and }not test_str_convert_ok_py39"
%endif
# https://github.com/tox-dev/tox/commit/698f1dd663
# Until we have setuptools 70.1+ we skip those
# The tests fail with setuptools < 70.1
%if v"%(%{python3} -c 'import importlib.metadata as im; print(im.version("setuptools"))' 2>/dev/null || echo 0)" < v"70.1"
k="${k-}${k+ and }not test_result_json_sequential"
k="${k-}${k+ and }not test_setuptools_package"
k="${k-}${k+ and }not test_skip_develop_mode"
k="${k-}${k+ and }not test_tox_install_pkg_sdist"
%else
# this test fails with virtualenv < 20.31 with bundled wheel
test -z $VIRTUALENV_WHEEL || k="${k-}${k+ and }not test_result_json_sequential"
%endif
# The following tests either need internet connection or installed tox
# so we only run them on the CI.
%if %{without ci_tests}
k="${k-}${k+ and }not test_virtualenv_flipped_settings"
k="${k-}${k+ and }not test_virtualenv_env_ignored_if_set"
k="${k-}${k+ and }not test_virtualenv_env_used_if_not_set"
k="${k-}${k+ and }not test_build_wheel_external"
k="${k-}${k+ and }not keyboard_interrupt"
k="${k-}${k+ and }not test_call_as_module"
k="${k-}${k+ and }not test_call_as_exe"
k="${k-}${k+ and }not test_run_installpkg_targz"
test -z $VIRTUALENV_WHEEL && k="${k-}${k+ and }not test_result_json_sequential"
%endif
%pytest -v -n auto -k "${k-}" --run-integration
+3
View File
@@ -0,0 +1,3 @@
Filters = [
'spelling-error .* en_US [Vv]irtualenv ',
]
+1 -1
View File
@@ -1 +1 @@
SHA512 (tox-4.24.1.tar.gz) = 8d7a3cd9c6140463dd2d2e1df7845c676f750ca23c0a9d528ee4fc7923bcadea94cfc0e7a1d70bd436d867be5f2edddd1576569777f2c15a0e11768cd932b6dd
SHA512 (tox-4.26.0.tar.gz) = ad2e311cd63c45a079b8c230a2feb364270b7a8bcf44b626385f8e442c6683ae841b3f34417b504f927608685a254fef3767d832fb5cfcc324c9cbf6ff7ea997
+19 -20
View File
@@ -30,39 +30,45 @@
- all_supplementing_pythons:
dir: tests
run: ./all_supplementing_pythons.py
- smoke27_optional:
- smoke27:
dir: python/smoke
run: VERSION=2.7 INSTALL_OR_SKIP=true METHOD=virtualenv TOX_REQUIRES="virtualenv<20.22.0" ./venv.sh
- smoke36:
dir: python/smoke
run: VERSION=3.6 TOX_REQUIRES="virtualenv<20.22.0" ./venv.sh
- smoke38_optional:
dir: python/smoke
run: VERSION=3.8 INSTALL_OR_SKIP=true ./venv.sh
run: VERSION=3.6 INSTALL_OR_SKIP=true TOX_REQUIRES="virtualenv<20.22.0" ./venv.sh
- smoke39:
dir: python/smoke
run: VERSION=3.9 ./venv.sh
run: VERSION=3.9 INSTALL_OR_SKIP=true ./venv.sh
- smoke310:
dir: python/smoke
run: VERSION=3.10 ./venv.sh
run: VERSION=3.10 INSTALL_OR_SKIP=true ./venv.sh
- smoke311:
dir: python/smoke
run: VERSION=3.11 ./venv.sh
run: VERSION=3.11 INSTALL_OR_SKIP=true ./venv.sh
- smoke312:
dir: python/smoke
run: VERSION=3.12 ./venv.sh
- smoke313:
dir: python/smoke
run: VERSION=3.13 ./venv.sh
run: VERSION=3.13 INSTALL_OR_SKIP=true ./venv.sh
- smoke313t:
dir: python/smoke
run: VERSION=3.13t INSTALL_OR_SKIP=true ./venv.sh
- smoke314:
dir: python/smoke
run: VERSION=3.14 ./venv.sh
run: VERSION=3.14 INSTALL_OR_SKIP=true ./venv.sh
- smoke314t:
dir: python/smoke
run: VERSION=3.14t INSTALL_OR_SKIP=true ./venv.sh
- smoke_pypy39:
dir: python/smoke
run: PYTHON=pypy3.9 VERSION=3.9 ./venv.sh
run: PYTHON=pypy3.9 VERSION=3.9 INSTALL_OR_SKIP=true ./venv.sh
- smoke_pypy310:
dir: python/smoke
run: PYTHON=pypy3.10 VERSION=3.10 ./venv.sh
run: PYTHON=pypy3.10 VERSION=3.10 INSTALL_OR_SKIP=true ./venv.sh
- smoke_pypy311:
dir: python/smoke
run: PYTHON=pypy3.11 VERSION=3.11 INSTALL_OR_SKIP=true ./venv.sh
- pyproject_pytest:
dir: pyproject-rpm-macros/tests
run: ./mocktest.sh python-pytest
@@ -75,15 +81,8 @@
required_packages:
- gcc
- virtualenv
- python3.6
- python3.9
- python3.10-devel
- python3.11-devel
- python3-devel
- python3.12-devel
- python3.13-devel
- python3.14-devel
- pypy3.9-devel
- pypy3.10-devel
- python3-tox
- python3-dnf
- mock