Skip to content

Commit

Permalink
freq='B' is deprecated? issue 53446
Browse files Browse the repository at this point in the history
  • Loading branch information
aram-cinnamon committed Nov 17, 2024
1 parent eb44720 commit 1432e75
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions pandas/tests/plotting/test_datetimelike.py
Original file line number Diff line number Diff line change
Expand Up @@ -862,15 +862,12 @@ def test_mixed_freq_lf_first_hourly(self):
for line in ax.get_lines():
assert PeriodIndex(data=line.get_xdata()).freq == "min"

@pytest.mark.filterwarnings(r"ignore:PeriodDtype\[B\] is deprecated:FutureWarning")
def test_mixed_freq_irreg_period(self):
ts = Series(
np.arange(30, dtype=np.float64), index=date_range("2020-01-01", periods=30)
)
irreg = ts.iloc[[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 15, 16, 17, 18, 29]]
msg = r"PeriodDtype\[B\] is deprecated"
with tm.assert_produces_warning(FutureWarning, match=msg):
rng = period_range("1/3/2000", periods=30, freq="B")
rng = period_range("1/3/2000", periods=30, freq="D")
ps = Series(np.random.default_rng(2).standard_normal(len(rng)), rng)
_, ax = mpl.pyplot.subplots()
irreg.plot(ax=ax)
Expand Down

0 comments on commit 1432e75

Please sign in to comment.