diff --git a/pandas/api/tests/test_api.py b/pandas/api/tests/test_api.py index fda81ee6c9045..2537354091ad1 100644 --- a/pandas/api/tests/test_api.py +++ b/pandas/api/tests/test_api.py @@ -163,7 +163,7 @@ def test_types(self): self.check(types, self.allowed) def check_deprecation(self, fold, fnew): - with tm.assert_produces_warning(FutureWarning): + with tm.assert_produces_warning(DeprecationWarning): try: result = fold('foo') expected = fnew('foo') diff --git a/pandas/core/common.py b/pandas/core/common.py index 054b899f1ded2..341bd3b4cc845 100644 --- a/pandas/core/common.py +++ b/pandas/core/common.py @@ -31,7 +31,7 @@ def wrapper(*args, **kwargs): warnings.warn("pandas.core.common.{t} is deprecated. " "import from the public API: " "pandas.api.types.{t} instead".format(t=t), - FutureWarning, stacklevel=3) + DeprecationWarning, stacklevel=3) return getattr(types, t)(*args, **kwargs) return wrapper @@ -57,7 +57,7 @@ def wrapper(*args, **kwargs): "These are not longer public API functions, " "but can be imported from " "pandas.types.common.{t} instead".format(t=t), - FutureWarning, stacklevel=3) + DeprecationWarning, stacklevel=3) return getattr(common, t)(*args, **kwargs) return wrapper