forked from pool/python-pytz
Accepting request 244353 from devel:languages:python
- Run test suite during build (required disabling of one test as it is known to be broken) - Disable broken test (fix-tests.patch) OBS-URL: https://build.opensuse.org/request/show/244353 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pytz?expand=0&rev=14
This commit is contained in:
commit
c47aa04551
18
fix-tests.patch
Normal file
18
fix-tests.patch
Normal file
@ -0,0 +1,18 @@
|
||||
--- a/pytz/tests/test_tzinfo.py
|
||||
+++ b/pytz/tests/test_tzinfo.py
|
||||
@@ -694,15 +694,6 @@
|
||||
'1914-01-01 13:40:00 UTC+0000'
|
||||
)
|
||||
|
||||
- def no_testCreateLocaltime(self):
|
||||
- # It would be nice if this worked, but it doesn't.
|
||||
- tz = pytz.timezone('Europe/Amsterdam')
|
||||
- dt = datetime(2004, 10, 31, 2, 0, 0, tzinfo=tz)
|
||||
- self.assertEqual(
|
||||
- dt.strftime(fmt),
|
||||
- '2004-10-31 02:00:00 CET+0100'
|
||||
- )
|
||||
-
|
||||
|
||||
class CommonTimezonesTestCase(unittest.TestCase):
|
||||
def test_bratislava(self):
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jul 24 09:41:38 UTC 2014 - mcihar@suse.com
|
||||
|
||||
- Run test suite during build (required disabling of one test as
|
||||
it is known to be broken)
|
||||
- Disable broken test (fix-tests.patch)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Jul 23 12:08:31 UTC 2014 - mcihar@suse.cz
|
||||
|
||||
|
@ -24,9 +24,11 @@ License: MIT
|
||||
Group: Development/Languages/Python
|
||||
Url: http://pytz.sourceforge.net
|
||||
Source: http://pypi.python.org/packages/source/p/pytz/pytz-%{version}.tar.bz2
|
||||
# PATCH-FIX-UPSTREAM fix-tests.patch -- Remote tests which are known to be broken
|
||||
Patch0: fix-tests.patch
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-devel
|
||||
#BuildRequires: python-nose
|
||||
BuildRequires: python-nose
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
||||
%{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
|
||||
@ -49,6 +51,8 @@ Amost all of the Olson timezones are supported.
|
||||
|
||||
%prep
|
||||
%setup -q -n pytz-%{version}
|
||||
# Disable test which is not working (and documented so)
|
||||
%patch0 -p1
|
||||
# For rpmlint warning: remove shebang from python library:
|
||||
sed -i '/^#!/d' ./pytz/tzfile.py
|
||||
|
||||
@ -59,8 +63,8 @@ python setup.py build
|
||||
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
||||
%fdupes %{buildroot}%{python_sitelib}
|
||||
|
||||
#%%check
|
||||
#nosetests
|
||||
%check
|
||||
nosetests
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
|
Loading…
x
Reference in New Issue
Block a user