Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-qstylizer for 
openSUSE:Factory checked in at 2024-01-07 21:40:56
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-qstylizer (Old)
 and      /work/SRC/openSUSE:Factory/.python-qstylizer.new.28375 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-qstylizer"

Sun Jan  7 21:40:56 2024 rev:6 rq:1137421 version:0.2.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-qstylizer/python-qstylizer.changes        
2022-10-08 01:25:24.354254552 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-qstylizer.new.28375/python-qstylizer.changes 
    2024-01-07 21:41:13.694039972 +0100
@@ -1,0 +2,6 @@
+Sun Jan  7 17:31:10 UTC 2024 - Ben Greiner <[email protected]>
+
+- Add qstylizer-pr17-fix-py12-mock.patch gh#blambright/qstylizer#17
+- Move to PEP517 build
+
+-------------------------------------------------------------------

New:
----
  qstylizer-pr17-fix-py12-mock.patch

BETA DEBUG BEGIN:
  New:
- Add qstylizer-pr17-fix-py12-mock.patch gh#blambright/qstylizer#17
- Move to PEP517 build
BETA DEBUG END:

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-qstylizer.spec ++++++
--- /var/tmp/diff_new_pack.FxSQeH/_old  2024-01-07 21:41:14.550071110 +0100
+++ /var/tmp/diff_new_pack.FxSQeH/_new  2024-01-07 21:41:14.550071110 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-qstylizer
 #
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2024 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -16,7 +16,6 @@
 #
 
 
-%{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-qstylizer
 Version:        0.2.2
 Release:        0
@@ -25,8 +24,12 @@
 URL:            https://github.com/blambright/qstylizer
 # no sdist on PyPI
 Source:         
https://github.com/blambright/qstylizer/archive/refs/tags/%{version}.tar.gz#/qstylizer-%{version}-gh.tar.gz
+# PATCH-FIX-UPSTREAM qstylizer-pr17-fix-py12-mock.patch 
gh#blambright/qstylizer#17
+Patch0:         
https://github.com/blambright/qstylizer/pull/17.patch#/qstylizer-pr17-fix-py12-mock.patch
 BuildRequires:  %{python_module pbr}
+BuildRequires:  %{python_module pip}
 BuildRequires:  %{python_module setuptools}
+BuildRequires:  %{python_module wheel}
 BuildRequires:  python-rpm-macros
 # SECTION test requirements
 BuildRequires:  %{python_module inflection > 0.3.0}
@@ -51,11 +54,11 @@
 
 %build
 export PBR_VERSION=%{version}
-%python_build
+%pyproject_wheel
 
 %install
 export PBR_VERSION=%{version}
-%python_install
+%pyproject_install
 %python_expand %fdupes %{buildroot}%{$python_sitelib}
 
 %check
@@ -65,5 +68,5 @@
 %doc README.rst
 %license LICENSE.txt
 %{python_sitelib}/qstylizer
-%{python_sitelib}/qstylizer-%{version}*-info
+%{python_sitelib}/qstylizer-%{version}.dist-info
 

++++++ qstylizer-pr17-fix-py12-mock.patch ++++++
>From dac82fc9204dd0a2e34ca5d2da508b7874da7d91 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <[email protected]>
Date: Sun, 5 Nov 2023 17:18:49 +0100
Subject: [PATCH] Fix typo in tests: use assert_called_once_with()

Fix a typo in tests whereas `.called_once_with()` is called rather than
`.assert_called_once_with()`.  This gets mocked in Python < 3.12
and therefore it is ignored (but doesn't test correctly) but it triggers
an error in Python 3.12:

```
E               AttributeError: 'called_once_with' is not a valid assertion. 
Use a spec for the mock if 'called_once_with' is meant to be an attribute.. Did 
you mean: 'assert_called_once_with'?
```
---
 test/unit/test_style.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/unit/test_style.py b/test/unit/test_style.py
index a911822..36b5296 100644
--- a/test/unit/test_style.py
+++ b/test/unit/test_style.py
@@ -184,7 +184,7 @@ def test_create_child_rule_list(mocker, style_class, css):
     )
     mocked_set_child_rule = mocker.patch.object(style_class, "set_child_rule")
     assert css.create_child_rule_list(name) == style_list
-    mocked_set_child_rule.called_once_with(name, style_list)
+    mocked_set_child_rule.assert_called_once_with(name, style_list)
 
 
 @pytest.mark.parametrize(

Reply via email to