[pandas] 01/02: Try to exclude tests that fail on other architectures than Intel

Andreas Tille tille at debian.org
Sat Oct 14 20:55:11 UTC 2017


This is an automated email from the git hooks/post-receive script.

tille pushed a commit to branch debian
in repository pandas.

commit f77587a32f4746fc970ae0ce150fda5ed21b0407
Author: Andreas Tille <tille at debian.org>
Date:   Sat Oct 14 19:48:32 2017 +0200

    Try to exclude tests that fail on other architectures than Intel
---
 debian/changelog                                 |   8 ++
 debian/patches/mark_tests_working_on_intel.patch | 111 +++++++++++++++++++++++
 debian/patches/series                            |   1 +
 debian/rules                                     |   5 +-
 4 files changed, 124 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 5c5baf9..cf2787c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+pandas (0.20.3-4) UNRELEASED; urgency=medium
+
+  * Mark those tests @pytest.mark.intel that pass only on Intel architectures
+  * d/rules: try to exclude tests that were marked "intel"
+    (Concerns bug #877419)
+
+ -- Andreas Tille <tille at debian.org>  Sat, 14 Oct 2017 19:42:59 +0200
+
 pandas (0.20.3-3) unstable; urgency=medium
 
   * Team upload.
diff --git a/debian/patches/mark_tests_working_on_intel.patch b/debian/patches/mark_tests_working_on_intel.patch
new file mode 100644
index 0000000..fc61690
--- /dev/null
+++ b/debian/patches/mark_tests_working_on_intel.patch
@@ -0,0 +1,111 @@
+Description: Mark those tests @pytest.mark.intel that pass only on Intel architectures
+Author: Andreas Tille <tille at debian.org>
+Last-Update Sat, 14 Oct 2017 19:42:59 +0200
+Bug-Debian: https://bugs.debian.org/877419
+
+--- a/pandas/tests/test_algos.py
++++ b/pandas/tests/test_algos.py
+@@ -747,6 +747,7 @@ class TestValueCounts(object):
+             expected = Series([2, 1, 1], index=[5., 10.3, np.nan])
+             tm.assert_series_equal(result, expected)
+ 
++    @pytest.mark.intel
+     def test_value_counts_normalized(self):
+         # GH12558
+         s = Series([1, 2, np.nan, np.nan, np.nan])
+--- a/pandas/tests/test_resample.py
++++ b/pandas/tests/test_resample.py
+@@ -2152,6 +2152,7 @@ class TestDatetimeIndex(Base):
+ 
+         assert_frame_equal(frame.resample('60s').mean(), frame_3s)
+ 
++    @pytest.mark.intel
+     def test_resample_timedelta_values(self):
+         # GH 13119
+         # check that timedelta dtype is preserved when NaT values are
+@@ -2169,6 +2170,7 @@ class TestDatetimeIndex(Base):
+         res = df['time'].resample('2D').first()
+         tm.assert_series_equal(res, exp)
+ 
++    @pytest.mark.intel
+     def test_resample_datetime_values(self):
+         # GH 13119
+         # check that datetime dtype is preserved when NaT values are
+--- a/pandas/tests/dtypes/test_cast.py
++++ b/pandas/tests/dtypes/test_cast.py
+@@ -67,6 +67,7 @@ class TestMaybeDowncast(object):
+             tm.assert_almost_equal(result, np.array([], dtype=np.int64))
+             assert result.dtype == np.int64
+ 
++    @pytest.mark.intel
+     def test_datetimelikes_nan(self):
+         arr = np.array([1, 2, np.nan])
+         exp = np.array([1, 2, np.datetime64('NaT')], dtype='datetime64[ns]')
+--- a/pandas/tests/frame/test_indexing.py
++++ b/pandas/tests/frame/test_indexing.py
+@@ -2607,6 +2607,7 @@ class TestDataFrameIndexing(TestData):
+         result = a.where(do_not_replace, b)
+         assert_frame_equal(result, expected)
+ 
++    @pytest.mark.intel
+     def test_where_datetime(self):
+ 
+         # GH 3311
+--- a/pandas/tests/series/test_indexing.py
++++ b/pandas/tests/series/test_indexing.py
+@@ -1378,6 +1378,7 @@ class TestSeriesIndexing(TestData):
+         expected = Series([5, 11, 2, 5, 11, 2], index=[0, 1, 2, 0, 1, 2])
+         assert_series_equal(comb, expected)
+ 
++    @pytest.mark.intel
+     def test_where_datetime(self):
+         s = Series(date_range('20130102', periods=2))
+         expected = Series([10, 10], dtype='datetime64[ns]')
+@@ -1407,6 +1408,7 @@ class TestSeriesIndexing(TestData):
+         expected = Series([pd.NaT, s[1]])
+         assert_series_equal(rs, expected)
+ 
++    @pytest.mark.intel
+     def test_where_timedelta(self):
+         s = Series([1, 2], dtype='timedelta64[ns]')
+         expected = Series([10, 10], dtype='timedelta64[ns]')
+--- a/pandas/tests/frame/test_operators.py
++++ b/pandas/tests/frame/test_operators.py
+@@ -177,6 +177,7 @@ class TestDataFrameOperators(TestData):
+             df)), 'b': date_range('20100101', periods=len(df))})
+         check(df, df2)
+ 
++    @pytest.mark.intel
+     def test_timestamp_compare(self):
+         # make sure we can compare Timestamps on the right AND left hand side
+         # GH4982
+--- a/pandas/tests/groupby/test_aggregate.py
++++ b/pandas/tests/groupby/test_aggregate.py
+@@ -131,6 +131,7 @@ class TestGroupByAggregate(object):
+         grouped = df.groupby(df.index.month)
+         list(grouped)
+ 
++    @pytest.mark.intel
+     def test_agg_dict_parameter_cast_result_dtypes(self):
+         # GH 12821
+ 
+--- a/pandas/tests/series/test_constructors.py
++++ b/pandas/tests/series/test_constructors.py
+@@ -828,6 +828,7 @@ class TestSeriesConstructors(TestData):
+         series[2] = val
+         assert isnull(series[2])
+ 
++    @pytest.mark.intel
+     def test_NaT_cast(self):
+         # GH10747
+         result = Series([np.nan]).astype('M8[ns]')
+--- a/pandas/tests/series/test_period.py
++++ b/pandas/tests/series/test_period.py
+@@ -94,6 +94,7 @@ class TestSeriesPeriod(object):
+         series[2] = val
+         assert isnull(series[2])
+ 
++    @pytest.mark.intel
+     def test_NaT_cast(self):
+         result = Series([np.nan]).astype('period[D]')
+         expected = Series([NaT])
diff --git a/debian/patches/series b/debian/patches/series
index 763ab28..dd70213 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -10,3 +10,4 @@ deb_skip_sequencelike_on_armel
 up_print_versions
 up_network_seaborn
 dateutil-2.6.1-fixed-ambiguous-tz-dst-be.patch
+mark_tests_working_on_intel.patch
diff --git a/debian/rules b/debian/rules
index 186ae36..a1523d3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -25,7 +25,10 @@ UVER_PYSHORT := $(shell echo $(UVER_PY) | sed -e 's,+git.*,,g')
 MIN_CYTHONVER = 0.23
 
 ifeq ($(DEB_HOST_ARCH),$(filter $(DEB_HOST_ARCH), arm64 armel armhf mips mips64el mipsel s390x alpha hppa powerpc ppc64))
-	EXCLUDE_TESTS_ARCH := --exclude 'test(test_value_counts_normalized|test_resample_timedelta_values|test_resample_datetime_values|test_datetimelikes_nan|test_where_datetime|test_timestamp_compare|test_agg_dict_parameter_cast_result_dtypes|test_NaT_cast|test_where_datetime|test_where_timedelta)'
+	# EXCLUDE_TESTS_ARCH := --exclude 'test(test_value_counts_normalized|test_resample_timedelta_values|test_resample_datetime_values|test_datetimelikes_nan|test_where_datetime|test_timestamp_compare|test_agg_dict_parameter_cast_result_dtypes|test_NaT_cast|test_where_datetime|test_where_timedelta)'
+	# unfortunately this leads to:
+	#	pytest.py: error: unrecognized arguments: --exclude
+	EXCLUDE_TESTS_ARCH := -m "not intel"
 else
 	EXCLUDE_TESTS_ARCH :=
 endif

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/pandas.git



More information about the debian-science-commits mailing list