Package: protontricks
Version: 1.10.5-1
Followup-For: Bug #1063967
X-Debbugs-Cc: chris.peter...@canonical.com
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu oracular ubuntu-patch
Control: tags -1 patch



Hi,

I applied the following patch in Ubuntu to fix this issue.


  * pytest8-caplog.patch: Update tests for pytest 8 compatibility
    (LP: #2068659).


Thanks for considering the patch.


-- System Information:
Debian Release: trixie/sid
  APT prefers oracular
  APT policy: (500, 'oracular'), (100, 'oracular-proposed')
Architecture: amd64 (x86_64)

Kernel: Linux 6.8.0-31-generic (SMP w/16 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
diff -Nru protontricks-1.10.5/debian/patches/pytest8-caplog.patch 
protontricks-1.10.5/debian/patches/pytest8-caplog.patch
--- protontricks-1.10.5/debian/patches/pytest8-caplog.patch     1969-12-31 
16:00:00.000000000 -0800
+++ protontricks-1.10.5/debian/patches/pytest8-caplog.patch     2024-06-06 
12:27:04.000000000 -0700
@@ -0,0 +1,37 @@
+Description: Update test for pytest 8 comptability
+ Pytest 8 now includes all log levels in the caplog fixture. Apply upstream
+ changes to test case which ensures warning messages are logged. Can be dropped
+ in upstream version 1.11.1
+Author: Chris Peterson <chirs.peter...@canonical.com>
+Origin: upstream, 
https://github.com/Matoking/protontricks/commit/bb1da5a0ddcac1cbd577fd54fe947ff6ad1731bc
+Bug: https://github.com/Matoking/protontricks/issues/283
+Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/pytest/+bug/2068659
+Forwarded: not-needed
+Last-Update: 2024-06-06
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+--- a/tests/test_gui.py
++++ b/tests/test_gui.py
+@@ -207,7 +207,7 @@
+         assert steam_app == steam_apps[1]
+         assert (
+             "Your system locale is incapable of displaying all characters"
+-            in caplog.records[0].message
++            in caplog.records[-1].message
+         )
+ 
+     @pytest.mark.parametrize("gui_cmd", ["yad", "zenity"])
+--- a/tests/conftest.py
++++ b/tests/conftest.py
+@@ -44,6 +44,11 @@
+     logging.getLogger("protontricks").handlers.clear()
+ 
+ 
++@pytest.fixture(scope="function", autouse=True)
++def default_caplog(caplog):
++    caplog.set_level(logging.INFO)
++
++
+ @pytest.fixture(scope="function")
+ def verbose_logging():
+     """
diff -Nru protontricks-1.10.5/debian/patches/series 
protontricks-1.10.5/debian/patches/series
--- protontricks-1.10.5/debian/patches/series   1969-12-31 16:00:00.000000000 
-0800
+++ protontricks-1.10.5/debian/patches/series   2024-06-06 12:26:50.000000000 
-0700
@@ -0,0 +1 @@
+pytest8-caplog.patch

Reply via email to