From 466a91faf71b9494c43a8f2f7bd9bbe06d69c829 Mon Sep 17 00:00:00 2001 From: gfyoung Date: Thu, 21 Jun 2018 23:17:16 -0700 Subject: [PATCH] TST: Use int fixtures in test_construction.py Partially addresses gh-21500. --- pandas/tests/indexes/datetimes/test_construction.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/pandas/tests/indexes/datetimes/test_construction.py b/pandas/tests/indexes/datetimes/test_construction.py index f7682a965c038..ae98510951845 100644 --- a/pandas/tests/indexes/datetimes/test_construction.py +++ b/pandas/tests/indexes/datetimes/test_construction.py @@ -524,14 +524,13 @@ def test_dti_constructor_years_only(self, tz_naive_fixture): (rng3, expected3), (rng4, expected4)]: tm.assert_index_equal(rng, expected) - @pytest.mark.parametrize('dtype', [np.int64, np.int32, np.int16, np.int8]) - def test_dti_constructor_small_int(self, dtype): - # GH 13721 + def test_dti_constructor_small_int(self, any_int_dtype): + # see gh-13721 exp = DatetimeIndex(['1970-01-01 00:00:00.00000000', '1970-01-01 00:00:00.00000001', '1970-01-01 00:00:00.00000002']) - arr = np.array([0, 10, 20], dtype=dtype) + arr = np.array([0, 10, 20], dtype=any_int_dtype) tm.assert_index_equal(DatetimeIndex(arr), exp) def test_ctor_str_intraday(self):