From 924b60ad1fcb43a167e1f3e850efc8a68e6a4ce9 Mon Sep 17 00:00:00 2001 From: Simon Hawkins Date: Mon, 11 Mar 2019 12:44:21 +0000 Subject: [PATCH] CLN: remove pandas.core.categorical --- pandas/core/categorical.py | 9 --------- pandas/tests/api/test_api.py | 17 ----------------- 2 files changed, 26 deletions(-) delete mode 100644 pandas/core/categorical.py diff --git a/pandas/core/categorical.py b/pandas/core/categorical.py deleted file mode 100644 index 43c35c4000bb6..0000000000000 --- a/pandas/core/categorical.py +++ /dev/null @@ -1,9 +0,0 @@ -import warnings - -from pandas.core.dtypes.dtypes import CategoricalDtype # noqa - -from pandas.core.arrays import Categorical # noqa - -# TODO: Remove after 0.23.x -warnings.warn("'pandas.core' is private. Use 'pandas.Categorical'", - FutureWarning, stacklevel=2) diff --git a/pandas/tests/api/test_api.py b/pandas/tests/api/test_api.py index 599ab9a3c5f7c..e27c8fc93233a 100644 --- a/pandas/tests/api/test_api.py +++ b/pandas/tests/api/test_api.py @@ -1,6 +1,4 @@ # -*- coding: utf-8 -*- -import sys - import pandas as pd from pandas import api from pandas.util import testing as tm @@ -148,18 +146,3 @@ def test_deprecation_cdaterange(self): with tm.assert_produces_warning(FutureWarning, check_stacklevel=False): cdate_range('2017-01-01', '2017-12-31') - - -class TestCategoricalMove(object): - - def test_categorical_move(self): - # May have been cached by another import, e.g. pickle tests. - sys.modules.pop("pandas.core.categorical", None) - - with tm.assert_produces_warning(FutureWarning): - from pandas.core.categorical import Categorical # noqa - - sys.modules.pop("pandas.core.categorical", None) - - with tm.assert_produces_warning(FutureWarning): - from pandas.core.categorical import CategoricalDtype # noqa