Skip to content

Commit

Permalink
Use pandas.testing (#4138)
Browse files Browse the repository at this point in the history
`pandas.util.testing` is deprecated. The preferred way forward is to use
`pandas.testing`. So this updates our usage accordingly.
  • Loading branch information
jakirkham authored Oct 2, 2020
1 parent 111029d commit 0c2c9f8
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion distributed/tests/test_collections.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
from distutils.version import LooseVersion

import pytest

pytest.importorskip("numpy")
Expand All @@ -11,7 +13,14 @@
from distributed.utils_test import client, cluster_fixture, loop # noqa F401
import numpy as np
import pandas as pd
import pandas.testing as tm

PANDAS_VERSION = LooseVersion(pd.__version__)
PANDAS_GT_100 = PANDAS_VERSION >= LooseVersion("1.0.0")

if PANDAS_GT_100:
import pandas.testing as tm # noqa: F401
else:
import pandas.util.testing as tm # noqa: F401


dfs = [
Expand Down

0 comments on commit 0c2c9f8

Please sign in to comment.