Hello community,

here is the log from the commit of package python-pytz for openSUSE:Factory 
checked in at 2019-01-26 22:19:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pytz (Old)
 and      /work/SRC/openSUSE:Factory/.python-pytz.new.28833 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-pytz"

Sat Jan 26 22:19:21 2019 rev:30 rq:668134 version:2018.5

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pytz/python-pytz.changes  2018-12-27 
00:28:05.375727024 +0100
+++ /work/SRC/openSUSE:Factory/.python-pytz.new.28833/python-pytz.changes       
2019-01-26 22:19:23.139002920 +0100
@@ -1,0 +2,8 @@
+Wed Jan  9 18:18:15 CET 2019 - [email protected]
+
+- Replace nose test runner with pytest (py2k stdlib unittest
+  runner is not sufficient to run the test suite here).
+- Refresh patches fix-tests.patch, system_zoneinfo.patch,
+  0001-Fix-tests-for-older-timezone-versions.patch
+
+-------------------------------------------------------------------

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

Other differences:
------------------
++++++ python-pytz.spec ++++++
--- /var/tmp/diff_new_pack.CbYkfc/_old  2019-01-26 22:19:23.707002460 +0100
+++ /var/tmp/diff_new_pack.CbYkfc/_new  2019-01-26 22:19:23.711002456 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package python-pytz
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -34,8 +34,11 @@
 Patch1:         system_zoneinfo.patch
 # PATCH-FIX-UPSTREAM 0001-Fix-tests-for-older-timezone-versions.patch -- 
https://code.launchpad.net/~toabctl/pytz/+git/pytz/+merge/326419
 Patch2:         0001-Fix-tests-for-older-timezone-versions.patch
+BuildRequires:  %{python_module base}
+# pytest is required only because of 2.7 stdlib test runner, python3
+# unittest runner is sufficient.
+BuildRequires:  %{python_module pytest}
 # Test requirements
-BuildRequires:  %{python_module nose}
 BuildRequires:  fdupes
 BuildRequires:  python-rpm-macros
 BuildRequires:  timezone
@@ -59,11 +62,7 @@
 
 %prep
 %setup -q -n pytz-%{version}
-# Disable test which is not working (and documented so)
-%patch0 -p1
-# Use system tz database
-%patch1 -p1
-%patch2 -p2
+%autopatch -p1
 
 # For rpmlint warning: remove shebang from python library:
 sed -i '/^#!/d' ./pytz/tzfile.py
@@ -76,7 +75,7 @@
 %python_expand rm -fr %{buildroot}%{$python_sitelib}/pytz/zoneinfo
 
 %check
-%python_expand nosetests-%{$python_bin_suffix}
+%python_expand PYTHONPATH=. py.test-%{$python_bin_suffix} -v pytz/tests
 
 %files %{python_files}
 %license LICENSE.txt

++++++ 0001-Fix-tests-for-older-timezone-versions.patch ++++++
--- /var/tmp/diff_new_pack.CbYkfc/_old  2019-01-26 22:19:23.723002446 +0100
+++ /var/tmp/diff_new_pack.CbYkfc/_new  2019-01-26 22:19:23.723002446 +0100
@@ -8,11 +8,9 @@
  src/pytz/tests/test_tzinfo.py | 26 ++++++++++++++------------
  1 file changed, 14 insertions(+), 12 deletions(-)
 
-diff --git a/src/pytz/tests/test_tzinfo.py b/src/pytz/tests/test_tzinfo.py
-index 3166322..0ecb8c0 100644
---- a/src/pytz/tests/test_tzinfo.py
-+++ b/src/pytz/tests/test_tzinfo.py
-@@ -249,13 +249,14 @@ class USEasternDSTStartTestCase(unittest.TestCase):
+--- a/pytz/tests/test_tzinfo.py
++++ b/pytz/tests/test_tzinfo.py
+@@ -247,12 +247,13 @@ class USEasternDSTStartTestCase(unittest
  
      def _test_tzname(self, utc_dt, wanted):
          tzname = wanted['tzname']
@@ -24,16 +22,14 @@
 -            'Expected %s as tzname for %s. Got %s' % (
 -                tzname, str(utc_dt), dt.tzname()
 -            )
--        )
 +        self.assertIn(dt.tzname(), tzname,
 +                      'Expected %s as tzname for %s. Got %s' % (
 +                          tzname, str(utc_dt), dt.tzname()
 +                      )
-+        )
+         )
  
      def _test_utcoffset(self, utc_dt, wanted):
-         utcoffset = wanted['utcoffset']
-@@ -512,7 +514,7 @@ class 
NoumeaHistoryStartTestCase(USEasternDSTStartTestCase):
+@@ -510,7 +511,7 @@ class NoumeaHistoryStartTestCase(USEaste
          'dst': timedelta(0),
      }
      after = {
@@ -42,7 +38,7 @@
          'utcoffset': timedelta(hours=11),
          'dst': timedelta(0),
      }
-@@ -523,12 +525,12 @@ class NoumeaDSTEndTestCase(USEasternDSTStartTestCase):
+@@ -521,12 +522,12 @@ class NoumeaDSTEndTestCase(USEasternDSTS
      tzinfo = pytz.timezone('Pacific/Noumea')
      transition_time = datetime(1997, 3, 1, 15, 00, 00, tzinfo=UTC)
      before = {
@@ -57,7 +53,7 @@
          'utcoffset': timedelta(hours=11),
          'dst': timedelta(0),
      }
-@@ -552,7 +554,7 @@ class TahitiTestCase(USEasternDSTStartTestCase):
+@@ -550,7 +551,7 @@ class TahitiTestCase(USEasternDSTStartTe
          'dst': timedelta(0),
      }
      after = {
@@ -66,7 +62,7 @@
          'utcoffset': timedelta(hours=-10),
          'dst': timedelta(0),
      }
-@@ -565,12 +567,12 @@ class 
SamoaInternationalDateLineChange(USEasternDSTStartTestCase):
+@@ -563,12 +564,12 @@ class SamoaInternationalDateLineChange(U
      tzinfo = pytz.timezone('Pacific/Apia')
      transition_time = datetime(2011, 12, 30, 10, 0, 0, tzinfo=UTC)
      before = {
@@ -81,7 +77,7 @@
          'utcoffset': timedelta(hours=14),
          'dst': timedelta(hours=1),
      }
-@@ -620,7 +622,7 @@ class LocalTestCase(unittest.TestCase):
+@@ -618,7 +619,7 @@ class LocalTestCase(unittest.TestCase):
  
          loc_time = loc_tz.localize(datetime(1940, 5, 10, 0, 0, 0))
          # pre-2017a, abbreviation was NCT
@@ -90,6 +86,3 @@
  
          loc_time = loc_tz.localize(datetime(1940, 5, 20, 0, 0, 0))
          self.assertEqual(loc_time.strftime('%Z%z'), 'CEST+0200')
--- 
-2.13.1
-

++++++ fix-tests.patch ++++++
--- /var/tmp/diff_new_pack.CbYkfc/_old  2019-01-26 22:19:23.731002440 +0100
+++ /var/tmp/diff_new_pack.CbYkfc/_new  2019-01-26 22:19:23.735002437 +0100
@@ -1,6 +1,6 @@
 --- a/pytz/tests/test_tzinfo.py
 +++ b/pytz/tests/test_tzinfo.py
-@@ -728,15 +728,6 @@
+@@ -726,15 +726,6 @@ class LocalTestCase(unittest.TestCase):
              '1914-01-01 13:40:00 UTC+0000'
          )
  



++++++ system_zoneinfo.patch ++++++
--- /var/tmp/diff_new_pack.CbYkfc/_old  2019-01-26 22:19:23.751002424 +0100
+++ /var/tmp/diff_new_pack.CbYkfc/_new  2019-01-26 22:19:23.751002424 +0100
@@ -1,8 +1,6 @@
-Index: pytz-2016.10/pytz/__init__.py
-===================================================================
---- pytz-2016.10.orig/pytz/__init__.py
-+++ pytz-2016.10/pytz/__init__.py
-@@ -90,23 +90,7 @@ def open_resource(name):
+--- a/pytz/__init__.py
++++ b/pytz/__init__.py
+@@ -87,23 +87,7 @@ def open_resource(name):
      for part in name_parts:
          if part == os.path.pardir or os.path.sep in part:
              raise ValueError('Bad path segment: %r' % part)
@@ -27,10 +25,8 @@
      return open(filename, 'rb')
  
  
-Index: pytz-2016.10/pytz/tzfile.py
-===================================================================
---- pytz-2016.10.orig/pytz/tzfile.py
-+++ pytz-2016.10/pytz/tzfile.py
+--- a/pytz/tzfile.py
++++ b/pytz/tzfile.py
 @@ -126,7 +126,7 @@ def build_tzinfo(zone, fp):
  if __name__ == '__main__':
      import os.path


Reply via email to