public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
To: git-commits@fedoraproject.org
Subject: [rpms/python-pytest-subprocess] rawhide: Fix tests with Python 3.15.2+
Date: Wed, 25 Nov 2026 16:26:46 GMT [thread overview]
Message-ID: <179562400625.1.7585966868358275487.rpms-python-pytest-subprocess-330a1d5e9f1d@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/python-pytest-subprocess
Branch : rawhide
Commit : 330a1d5e9f1dad63b0a27ba40f86956034b298a2
Author : Miro Hrončok <miro@hroncok.cz>
Date : 2026-11-25T15:02:17+01:00
Stats : +25/-0 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/python-pytest-subprocess/c/330a1d5e9f1dad63b0a27ba40f86956034b298a2?branch=rawhide
Log:
Fix tests with Python 3.15.2+
---
diff --git a/2207cd7c-test_check_call.patch b/2207cd7c-test_check_call.patch
new file mode 100644
index 0000000..447bcda
--- /dev/null
+++ b/2207cd7c-test_check_call.patch
@@ -0,0 +1,21 @@
+diff --git a/tests/test_subprocess.py b/tests/test_subprocess.py
+index 480ea25..1591926 100644
+--- a/tests/test_subprocess.py
++++ b/tests/test_subprocess.py
+@@ -311,11 +311,11 @@ def test_check_call(fp, fake):
+ assert subprocess.check_call((PYTHON, "example_script.py", "non-zero")) == 1
+
+ if sys.version_info >= (3, 6):
+- assert (
+- str(exc.value).replace("\\\\", "\\")
+- == f"Command '('{PYTHON}', 'example_script.py', 'non-zero')' "
+- "returned non-zero exit status 1."
+- )
++ command = (PYTHON, "example_script.py", "non-zero")
++ assert type(exc.value) is subprocess.CalledProcessError
++ assert exc.value.returncode == 1
++ assert exc.value.cmd == command
++ assert str(exc.value) == str(subprocess.CalledProcessError(1, command))
+
+
+ @pytest.mark.parametrize("fake", [False, True])
diff --git a/python-pytest-subprocess.spec b/python-pytest-subprocess.spec
index 837b32c..4c5af88 100644
--- a/python-pytest-subprocess.spec
+++ b/python-pytest-subprocess.spec
@@ -7,6 +7,10 @@ License: MIT
URL: https://github.com/aklajnert/pytest-subprocess
Source0: %{url}/archive/%{version}/pytest-subprocess-%{version}.tar.gz
+# Fix tests with Python 3.15.2+
+# Test-only changes taken from https://github.com/aklajnert/pytest-subprocess/commit/2207cd7c
+Patch: 2207cd7c-test_check_call.patch
+
BuildArch: noarch
BuildRequires: python3-devel
reply other threads:[~2026-11-25 16:26 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=179562400625.1.7585966868358275487.rpms-python-pytest-subprocess-330a1d5e9f1d@fedoraproject.org \
--to=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox