Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-pymilter for openSUSE:Factory 
checked in at 2024-03-06 23:04:54
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pymilter (Old)
 and      /work/SRC/openSUSE:Factory/.python-pymilter.new.1770 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-pymilter"

Wed Mar  6 23:04:54 2024 rev:6 rq:1155368 version:1.0.5

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pymilter/python-pymilter.changes  
2024-01-10 21:52:30.620650221 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-pymilter.new.1770/python-pymilter.changes    
    2024-03-06 23:05:26.847306486 +0100
@@ -1,0 +2,7 @@
+Tue Mar  5 18:22:42 UTC 2024 - Jaime Marquínez Ferrándiz 
<[email protected]>
+
+- Actually run the correct tests
+- Fix the fdupes call
+- Add 0001-Remove-calls-to-the-deprecated-method-assertEquals.patch
+
+-------------------------------------------------------------------

New:
----
  0001-Remove-calls-to-the-deprecated-method-assertEquals.patch

BETA DEBUG BEGIN:
  New:- Fix the fdupes call
- Add 0001-Remove-calls-to-the-deprecated-method-assertEquals.patch
BETA DEBUG END:

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

Other differences:
------------------
++++++ python-pymilter.spec ++++++
--- /var/tmp/diff_new_pack.Vot25p/_old  2024-03-06 23:05:27.671336386 +0100
+++ /var/tmp/diff_new_pack.Vot25p/_new  2024-03-06 23:05:27.675336531 +0100
@@ -30,6 +30,8 @@
 URL:            https://www.bmsi.com/python/milter.html
 Source0:        
https://github.com/sdgathman/pymilter/archive/pymilter-%{version}.tar.gz
 Source1:        tmpfiles-python-pymilter.conf
+# PATCH-FIX-UPSTREAM: https://github.com/sdgathman/pymilter/pull/57
+Patch1:         0001-Remove-calls-to-the-deprecated-method-assertEquals.patch
 BuildRequires:  %{python_module bsddb3}
 BuildRequires:  %{python_module devel}
 BuildRequires:  %{python_module setuptools}
@@ -72,10 +74,12 @@
 mkdir -p %{buildroot}%{_tmpfilesdir}
 install -m 0644 %{SOURCE1} %{buildroot}%{_tmpfilesdir}/%{name}.conf
 
-%fdupes %{buildroot}%{python_sitearch}
+%python_expand %fdupes %{buildroot}/%{$python_sitearch}
 
 %check
-%pyunittest_arch -v -k "not testPolicy"
+# remove tests that don't work
+rm test.py testpolicy.py
+%pyunittest_arch -v
 
 %files %{python_files}
 %doc README.md ChangeLog NEWS TODO CREDITS sample.py template.py

++++++ 0001-Remove-calls-to-the-deprecated-method-assertEquals.patch ++++++
>From 1ead9028fc63ae3ec6ea3b0c438e6ed088a2b20e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jaime=20Marqui=CC=81nez=20Ferra=CC=81ndiz?=
 <[email protected]>
Date: Tue, 5 Mar 2024 19:14:30 +0100
Subject: [PATCH] Remove calls to the deprecated method "assertEquals"
Reference: https://github.com/sdgathman/pymilter/pull/57

It has been removed in python 3.12
---
 testsample.py | 6 +++---
 testutils.py  | 4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/testsample.py b/testsample.py
index 100d1a6..70222bf 100644
--- a/testsample.py
+++ b/testsample.py
@@ -31,7 +31,7 @@ class BMSMilterTestCase(unittest.TestCase):
     count = 10
     while count > 0:
       rc = ctx._connect(helo='milter-template.example.org')
-      self.assertEquals(rc,Milter.CONTINUE)
+      self.assertEqual(rc,Milter.CONTINUE)
       with open('test/'+fname,'rb') as fp:
         rc = ctx._feedFile(fp)
       milter = ctx.getpriv()
@@ -46,7 +46,7 @@ class BMSMilterTestCase(unittest.TestCase):
     ctx._setsymval('{auth_type}','batcomputer')
     ctx._setsymval('j','mailhost')
     rc = ctx._connect()
-    self.assertEquals(rc,Milter.CONTINUE)
+    self.assertEqual(rc,Milter.CONTINUE)
     with open('test/'+fname,'rb') as fp:
       rc = ctx._feedFile(fp)
     milter = ctx.getpriv()
@@ -69,7 +69,7 @@ class BMSMilterTestCase(unittest.TestCase):
     milter = ctx.getpriv()
 #    self.assertTrue(milter.user == 'batman',"getsymval failed: "+
 #        "%s != %s"%(milter.user,'batman'))
-    self.assertEquals(milter.user,'batman')
+    self.assertEqual(milter.user,'batman')
     self.assertTrue(milter.auth_type != 'batcomputer',"setsymlist failed")
     self.assertTrue(rc == Milter.ACCEPT)
     self.assertTrue(ctx._bodyreplaced,"Message body not replaced")
diff --git a/testutils.py b/testutils.py
index 56ec161..93e078c 100644
--- a/testutils.py
+++ b/testutils.py
@@ -24,11 +24,11 @@ class AddrCacheTestCase(unittest.TestCase):
     self.assertTrue(cache.has_key('[email protected]'))
     self.assertTrue(not cache.has_key('[email protected]'))
     self.assertTrue('[email protected]' in cache)
-    self.assertEquals(cache['[email protected]'],'testing')
+    self.assertEqual(cache['[email protected]'],'testing')
     s = open(self.fname).readlines()
     self.assertTrue(len(s) == 2)
     self.assertTrue(s[0].startswith('[email protected] '))
-    self.assertEquals(s[1].strip(),'[email protected]')
+    self.assertEqual(s[1].strip(),'[email protected]')
     # check that new result overrides old
     cache['[email protected]'] = None
     self.assertTrue(not cache['[email protected]'])
-- 
2.44.0

Reply via email to