| 1373 | |
| 1374 | |
| 1375 | def test_dataframe_iterrows(df, pdf): |
| 1376 | if PANDAS_GE_320: |
| 1377 | # pandas 3.2 deprecated DataFrame.iterrows. Dask yields from the pandas |
| 1378 | # implementation, so the warning must surface rather than be suppressed. |
| 1379 | from pandas.errors import Pandas4Warning |
| 1380 | |
| 1381 | ctx = pytest.warns(Pandas4Warning, match="iterrows is deprecated") |
| 1382 | else: |
| 1383 | ctx = contextlib.nullcontext() |
| 1384 | |
| 1385 | with ctx: |
| 1386 | for a, b in zip(df.iterrows(), pdf.iterrows()): |
| 1387 | pd.testing.assert_series_equal(a[1], b[1]) |
| 1388 | |
| 1389 | |
| 1390 | def test_dataframe_itertuples(df, pdf): |