Skip to content

Commit 5500d02

Browse files
jrebackpcluo
authored andcommitted
TST: fix various deprecation warnings in tests suite (pandas-dev#16100)
1 parent f5680cd commit 5500d02

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

pandas/tests/frame/test_quantile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,7 @@ def test_quantile_empty(self):
431431
# res = df.quantile(0.5)
432432

433433
# datetimes
434-
df = DataFrame(columns=['a', 'b'], dtype='datetime64')
434+
df = DataFrame(columns=['a', 'b'], dtype='datetime64[ns]')
435435

436436
# FIXME (gives NaNs instead of NaT in 0.18.1 or 0.19.0)
437437
# res = df.quantile(0.5, numeric_only=False)

pandas/tests/io/formats/test_style.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -752,5 +752,6 @@ def test_from_custom_template(tmpdir):
752752
def test_shim():
753753
# https://github.com/pandas-dev/pandas/pull/16059
754754
# Remove in 0.21
755-
with pytest.warns(FutureWarning):
755+
with tm.assert_produces_warning(FutureWarning,
756+
check_stacklevel=False):
756757
from pandas.formats.style import Styler as _styler # noqa

pandas/tests/plotting/test_misc.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ def test_parallel_coordinates(self):
245245

246246
def test_parallel_coordinates_with_sorted_labels(self):
247247
""" For #15908 """
248-
from pandas.tools.plotting import parallel_coordinates
248+
from pandas.plotting import parallel_coordinates
249249

250250
df = DataFrame({"feat": [i for i in range(30)],
251251
"class": [2 for _ in range(10)] +

0 commit comments

Comments
 (0)