From a02e853a3a9ed3a459cc24f4d17537d56b4a107a Mon Sep 17 00:00:00 2001 From: Jeff Reback Date: Tue, 3 Oct 2017 09:01:05 -0400 Subject: [PATCH] TST: remove warnings, xref #15747 (#17761) --- pandas/tests/series/test_indexing.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pandas/tests/series/test_indexing.py b/pandas/tests/series/test_indexing.py index 86211612a59559..09ba0e197438dd 100644 --- a/pandas/tests/series/test_indexing.py +++ b/pandas/tests/series/test_indexing.py @@ -854,11 +854,15 @@ def test_basic_getitem_with_labels(self): s = Series(np.random.randn(10), index=lrange(0, 20, 2)) inds = [0, 2, 5, 7, 8] arr_inds = np.array([0, 2, 5, 7, 8]) - result = s[inds] + with tm.assert_produces_warning(FutureWarning, + check_stacklevel=False): + result = s[inds] expected = s.reindex(inds) assert_series_equal(result, expected) - result = s[arr_inds] + with tm.assert_produces_warning(FutureWarning, + check_stacklevel=False): + result = s[arr_inds] expected = s.reindex(arr_inds) assert_series_equal(result, expected)