MCPcopy
hub / github.com/pandas-dev/pandas / test_dataframe

Method test_dataframe

pandas/tests/plotting/test_datetimelike.py:378–390  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

376 assert not Index(rs).is_normalized
377
378 def test_dataframe(self):
379 bts = DataFrame(
380 {
381 "a": Series(
382 np.arange(10, dtype=np.float64),
383 index=date_range("2020-01-01", periods=10),
384 )
385 }
386 )
387 _, ax = mpl.pyplot.subplots()
388 bts.plot(ax=ax)
389 idx = ax.get_lines()[0].get_xdata()
390 tm.assert_index_equal(bts.index.to_period(), PeriodIndex(idx))
391
392 @pytest.mark.filterwarnings(
393 "ignore:Period with BDay freq is deprecated:FutureWarning"

Callers

nothing calls this directly

Calls 7

DataFrameClass · 0.90
SeriesClass · 0.90
date_rangeFunction · 0.90
PeriodIndexClass · 0.90
plotMethod · 0.45
get_linesMethod · 0.45
to_periodMethod · 0.45

Tested by

no test coverage detected