Accepting request 1109638 from home:mschreiner:branches:devel:languages:python

- Refresh mark-network-tests.patch for 4.11.1.
- Rewrite optional_devpi_process.patch for 4.11.1.
- Add explicit numpy built-time dependency, as the one pulled by
  pytest-randomly was broken.
- Fix rpmlint warning: package was obsoleting itself.
- Update to 4.11.1.
- Please check the .changes file for a more complete changelog.

OBS-URL: https://build.opensuse.org/request/show/1109638
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tox?expand=0&rev=109
This commit is contained in:
Matej Cepl 2023-09-08 17:15:07 +00:00 committed by Git OBS Bridge
parent 0d1407f509
commit 5fbce3fe15
6 changed files with 110 additions and 49 deletions

View File

@ -3,9 +3,11 @@
tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py | 1 + tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py | 1 +
2 files changed, 4 insertions(+) 2 files changed, 4 insertions(+)
--- a/pyproject.toml Index: tox-4.11.1/pyproject.toml
+++ b/pyproject.toml ===================================================================
@@ -162,6 +162,9 @@ ignore = [ --- tox-4.11.1.orig/pyproject.toml
+++ tox-4.11.1/pyproject.toml
@@ -133,6 +133,9 @@ ignore = [
[tool.pytest.ini_options] [tool.pytest.ini_options]
testpaths = ["tests"] testpaths = ["tests"]
addopts = "--tb=auto -ra --showlocals --no-success-flaky-report" addopts = "--tb=auto -ra --showlocals --no-success-flaky-report"
@ -13,11 +15,13 @@
+ "network: tests requiring network connection", + "network: tests requiring network connection",
+] +]
[tool.towncrier] [tool.coverage]
name = "tox" html.show_contexts = true
--- a/tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py Index: tox-4.11.1/tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py
+++ b/tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py ===================================================================
@@ -74,6 +74,7 @@ def test_install_pkg_via(tox_project: To --- tox-4.11.1.orig/tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py
+++ tox-4.11.1/tests/tox_env/python/virtual_env/package/test_package_cmd_builder.py
@@ -78,6 +78,7 @@ def test_install_pkg_via(tox_project: To
@pytest.mark.usefixtures("enable_pip_pypi_access") @pytest.mark.usefixtures("enable_pip_pypi_access")

View File

@ -1,42 +1,32 @@
--- Index: tox-4.11.1/src/tox/pytest.py
src/tox/pytest.py | 6 +++++- ===================================================================
tests/test_provision.py | 6 +++++- --- tox-4.11.1.orig/src/tox/pytest.py
2 files changed, 10 insertions(+), 2 deletions(-) +++ tox-4.11.1/src/tox/pytest.py
@@ -16,7 +16,10 @@ from typing import TYPE_CHECKING, Any, C
--- a/src/tox/pytest.py import pytest
+++ b/src/tox/pytest.py from _pytest.fixtures import SubRequest
@@ -26,7 +26,10 @@ from _pytest.logging import LogCaptureFi
from _pytest.monkeypatch import MonkeyPatch
from _pytest.python import Function
from _pytest.tmpdir import TempPathFactory
-from devpi_process import IndexServer -from devpi_process import IndexServer
+try: +try:
+ from devpi_process import IndexServer + from devpi_process import IndexServer
+except ImportError: +except ImportError:
+ IndexServer = None + IndexServer = None
from pytest_mock import MockerFixture
from virtualenv.info import fs_supports_symlink from virtualenv.info import fs_supports_symlink
@@ -473,6 +476,7 @@ def enable_pypi_server(monkeypatch: Monk import tox.run
Index: tox-4.11.1/tests/test_provision.py
===================================================================
@pytest.fixture(scope="session") --- tox-4.11.1.orig/tests/test_provision.py
+@pytest.mark.skipif(IndexServer is None, reason="requires devpi_process") +++ tox-4.11.1/tests/test_provision.py
def pypi_server(tmp_path_factory: TempPathFactory) -> Iterator[IndexServer]: @@ -16,7 +16,10 @@ from filelock import FileLock
# takes around 2.5s
path = tmp_path_factory.mktemp("pypi")
--- a/tests/test_provision.py
+++ b/tests/test_provision.py
@@ -12,7 +12,11 @@ from unittest import mock
from zipfile import ZipFile
import pytest
-from devpi_process import Index, IndexServer
+try:
+ from devpi_process import Index, IndexServer
+except ImportError:
+ Index = None
+ IndexServer = None
from filelock import FileLock
from packaging.requirements import Requirement from packaging.requirements import Requirement
if TYPE_CHECKING:
- from devpi_process import Index, IndexServer
+ try:
+ from devpi_process import Index, IndexServer
+ except ImportError:
+ Index, IndexServer = None, None
from tox.pytest import MonkeyPatch, TempPathFactory, ToxProjectCreator

View File

@ -1,3 +1,67 @@
-------------------------------------------------------------------
Mon Sep 4 21:12:18 UTC 2023 - Martin Schreiner <martin.schreiner@suse.com>
- Refresh mark-network-tests.patch for 4.11.1.
- Rewrite optional_devpi_process.patch for 4.11.1.
- Add explicit numpy built-time dependency, as the one pulled by
pytest-randomly was broken.
- Fix rpmlint warning: package was obsoleting itself.
- Update to 4.11.1:
- Changes from 4.11.1:
* Tests: Don't assume Python 3.10 is always installed, use current
Python version
* Set the --parallel default to "auto", not CPU count
* Fix , being used as value parser for env var configs
- Changes from 4.11.0:
* Fix type checker and bump tools
* Add config_settings support for build backend calls
- Changes from 4.10.0:
* Set basepython for docs env in alignment to Read the Docs
default
* Document release process
* Replace undefined settings with overrides when appending
* Accept environments with defined factors or of python selector
form - suggest closest
- Changes from 4.9.0:
* Disallow command line environments which are not explicitly
specified in the config file
- Changes from 4.8.0:
* Correct "notset" typo in --hashseed's --help text
* Bump pypa/gh-action-pypi-publish from 1.8.8 to 1.8.10
* Allow extending lists with --override foo+=bar
- Changes from 4.7.0:
* Fix doc alignment and link check
* Bump pypa/gh-action-pypi-publish from 1.8.7 to 1.8.8
* Update a test regex to work with Python 3.12+
* Remove broken link
* Add sponsor button for tidelift
* Make --hashseed default to PYTHONHASHSEED, if defined
- Changes from 4.6.4:
* Ensure tox r -e docs generates the documentation
* Bump pypa/gh-action-pypi-publish from 1.8.6 to 1.8.7
* s/setup.cfg/pyproject.toml/ in the development docs
* Fix hang and zombie process on interrupt (CTRL-C)
- Changes from 4.6.3:
* Made issue template have less whitespace
* Docs link of env var subs section to set_env
* Removed duplicate text in bug report template
* Ensure get_requires hook is called before prepare_metadata
- Changes from 4.6.2:
* Avoid cache collision between wheel and editable wheel builds
- Changes from 4.6.1:
* Update usedevelop doc
* Use ruff
- Changes from 4.6.0:
* Remove unnecessary Future usage
* Test against 3.12.0-beta.1
* Add --list-dependencies options
- Changes from 4.5.2:
* Add 3.12 support
* Bump pypa/gh-action-pypi-publish from 1.8.5 to 1.8.6
* Update list of maintainers
* Fix legacy tox --devenv venv
* Fix legacy devenv
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Jun 9 07:26:58 UTC 2023 - ecsos <ecsos@opensuse.org> Fri Jun 9 07:26:58 UTC 2023 - ecsos <ecsos@opensuse.org>

View File

@ -23,12 +23,11 @@
%bcond_with devpi_process %bcond_with devpi_process
%endif %endif
Name: python-tox Name: python-tox
Version: 4.5.1 Version: 4.11.1
Release: 0 Release: 0
Summary: Virtualenv-based automation of test activities Summary: Virtualenv-based automation of test activities
License: MIT License: MIT
URL: https://github.com/tox-dev/tox URL: https://github.com/tox-dev/tox
# Source: https://github.com/tox-dev/tox/archive/refs/tags/%%{version}.tar.gz#/tox-%%{version}.tar.gz
Source: https://files.pythonhosted.org/packages/source/t/tox/tox-%{version}.tar.gz Source: https://files.pythonhosted.org/packages/source/t/tox/tox-%{version}.tar.gz
# PATCH-FIX-OPENSUSE optional_devpi_process.patch bsc#[0-9]+ mcepl@suse.com # PATCH-FIX-OPENSUSE optional_devpi_process.patch bsc#[0-9]+ mcepl@suse.com
# Make use devpi_process optional # Make use devpi_process optional
@ -72,7 +71,7 @@ Requires: python-colorama
Requires: python-filelock >= 3.0.0 Requires: python-filelock >= 3.0.0
Requires: python-packaging >= 14 Requires: python-packaging >= 14
Requires: python-platformdirs >= 3.5.1 Requires: python-platformdirs >= 3.5.1
Requires: python-pluggy >= 0.12.0 Requires: python-pluggy >= 1.0.0
Requires: python-pyproject-api Requires: python-pyproject-api
Requires: python-tomli >= 2.0.1 Requires: python-tomli >= 2.0.1
Requires: python-virtualenv >= 20.0.8 Requires: python-virtualenv >= 20.0.8
@ -81,16 +80,17 @@ Requires(post): update-alternatives
Requires(postun):update-alternatives Requires(postun):update-alternatives
# last detox version is 0.19 # last detox version is 0.19
Obsoletes: python-detox <= 0.19 Obsoletes: python-detox <= 0.19
Provides: python-detox Provides: python-detox > 0.19
BuildArch: noarch BuildArch: noarch
# SECTION setup.cfg [options.extras_requires] testing= # SECTION setup.cfg [options.extras_requires] testing=
# (except for pytest-cov and -randomly) # (except for pytest-cov and -randomly)
BuildRequires: %{python_module flaky >= 3.4.0} BuildRequires: %{python_module flaky >= 3.4.0}
BuildRequires: %{python_module freezegun >= 0.3.11} BuildRequires: %{python_module freezegun >= 0.3.11}
BuildRequires: %{python_module numpy >= 1.25}
BuildRequires: %{python_module psutil >= 5.6.1} BuildRequires: %{python_module psutil >= 5.6.1}
BuildRequires: %{python_module pytest >= 4.0.0} BuildRequires: %{python_module pytest >= 4.0.0}
BuildRequires: %{python_module pytest-mock >= 1.10.0} BuildRequires: %{python_module pytest-mock >= 1.10.0}
BuildRequires: %{python_module pytest-randomly >= 1.0.0} BuildRequires: %{python_module pytest-randomly >= 3.0.0}
BuildRequires: %{python_module pytest-xdist >= 1.22.2} BuildRequires: %{python_module pytest-xdist >= 1.22.2}
# /SECTION # /SECTION
%if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3" %if "%{python_flavor}" == "python3" || "%{?python_provides}" == "python3"
@ -146,6 +146,9 @@ donttest+=" or test_parallel_live or (test_parallel and not test_parallel_)"
donttest+=" or test_replace_env_var_circular_flip_flop" donttest+=" or test_replace_env_var_circular_flip_flop"
# #
donttest+=" or test_call_as_exe or test_skip_pkg_install" donttest+=" or test_call_as_exe or test_skip_pkg_install"
donttest+=" or test_python_generate_hash_seed"
# this test doesn't work on aarch64
donttest+=" or test_bad_env_var"
%{python_expand # tests expect an active virtualenv with a clean python name as sys.executable %{python_expand # tests expect an active virtualenv with a clean python name as sys.executable
virtualenv-%{$python_bin_suffix} --system-site-packages testenv-%{$python_bin_suffix} virtualenv-%{$python_bin_suffix} --system-site-packages testenv-%{$python_bin_suffix}

3
tox-4.11.1.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8a8cc94b7269f8e43dfc636eff2da4b33a199a4e575b5b086cc51aae24ac4262
size 175185

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5a2eac5fb816779dfdf5cb00fecbc27eb0524e4626626bb1de84747b24cacc56
size 170137