diff options
author | Mark H Weaver <mhw@netris.org> | 2017-03-09 06:08:18 -0500 |
---|---|---|
committer | Mark H Weaver <mhw@netris.org> | 2017-03-09 06:08:18 -0500 |
commit | 7b1866d7835423554308f54e7736734731cfc0cb (patch) | |
tree | e45d50eb8d402990a02fdec8ebf0aadbe6baa1d9 | |
parent | 483188b76efcda27865a9d5082c99d91b9bde35b (diff) | |
download | patches-7b1866d7835423554308f54e7736734731cfc0cb.tar patches-7b1866d7835423554308f54e7736734731cfc0cb.tar.gz |
gnu: python-fake-factory: Add back missing patch file.
This reverts the removal of "python-fake-factory-fix-build-32bit.patch"
by commit ce7911ddae5d30ba73c8c9552b7d4e71268e5db3.
* gnu/packages/patches/python-fake-factory-fix-build-32bit.patch: New file.
* gnu/local.mk (dist_patch_DATA): Add it.
-rw-r--r-- | gnu/local.mk | 1 | ||||
-rw-r--r-- | gnu/packages/patches/python-fake-factory-fix-build-32bit.patch | 36 |
2 files changed, 37 insertions, 0 deletions
diff --git a/gnu/local.mk b/gnu/local.mk index 4297cbb965..cbd61e0972 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -862,6 +862,7 @@ dist_patch_DATA = \ %D%/packages/patches/python2-rdflib-drop-sparqlwrapper.patch \ %D%/packages/patches/python-statsmodels-fix-tests.patch \ %D%/packages/patches/python-configobj-setuptools.patch \ + %D%/packages/patches/python-fake-factory-fix-build-32bit.patch \ %D%/packages/patches/python-faker-fix-build-32bit.patch \ %D%/packages/patches/python-pandas-skip-failing-tests.patch \ %D%/packages/patches/python-paste-remove-website-test.patch \ diff --git a/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch b/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch new file mode 100644 index 0000000000..cb60896fad --- /dev/null +++ b/gnu/packages/patches/python-fake-factory-fix-build-32bit.patch @@ -0,0 +1,36 @@ +These tests fail on 32-bit due to an overflow. + +Upstream bug URL: https://github.com/joke2k/faker/issues/408 + +diff --git a/faker/tests/__init__.py b/faker/tests/__init__.py +index 6026772..58b6b83 100644 +--- a/faker/tests/__init__.py ++++ b/faker/tests/__init__.py +@@ -384,7 +384,6 @@ class FactoryTestCase(unittest.TestCase): + provider = Provider + # test century + self.assertTrue(self._datetime_to_time(provider.date_time_this_century(after_now=False)) <= self._datetime_to_time(datetime.datetime.now())) +- self.assertTrue(self._datetime_to_time(provider.date_time_this_century(before_now=False, after_now=True)) >= self._datetime_to_time(datetime.datetime.now())) + # test decade + self.assertTrue(self._datetime_to_time(provider.date_time_this_decade(after_now=False)) <= self._datetime_to_time(datetime.datetime.now())) + self.assertTrue(self._datetime_to_time(provider.date_time_this_decade(before_now=False, after_now=True)) >= self._datetime_to_time(datetime.datetime.now())) +@@ -413,8 +412,6 @@ class FactoryTestCase(unittest.TestCase): + + # ensure all methods provide timezone aware datetimes + with self.assertRaises(TypeError): +- provider.date_time_this_century(before_now=False, after_now=True, tzinfo=utc) >= datetime.datetime.now() +- with self.assertRaises(TypeError): + provider.date_time_this_decade(after_now=False, tzinfo=utc) <= datetime.datetime.now() + with self.assertRaises(TypeError): + provider.date_time_this_year(after_now=False, tzinfo=utc) <= datetime.datetime.now() +@@ -423,7 +420,6 @@ class FactoryTestCase(unittest.TestCase): + + # test century + self.assertTrue(provider.date_time_this_century(after_now=False, tzinfo=utc) <= datetime.datetime.now(utc)) +- self.assertTrue(provider.date_time_this_century(before_now=False, after_now=True, tzinfo=utc) >= datetime.datetime.now(utc)) + # test decade + self.assertTrue(provider.date_time_this_decade(after_now=False, tzinfo=utc) <= datetime.datetime.now(utc)) + self.assertTrue(provider.date_time_this_decade(before_now=False, after_now=True, tzinfo=utc) >= datetime.datetime.now(utc)) +-- +2.11.1 + |