MCPcopy Create free account
hub / github.com/dask/dask / test_dataframe_explode

Function test_dataframe_explode

dask/dataframe/tests/test_dataframe.py:4834–4842  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

4832
4833@pytest.mark.skip_with_pyarrow_strings # has to be array to explode
4834def test_dataframe_explode():
4835 df = pd.DataFrame({"A": [[1, 2, 3], "foo", [3, 4]], "B": 1})
4836 exploded_df = df.explode("A")
4837
4838 ddf = dd.from_pandas(df, npartitions=2)
4839
4840 exploded_ddf = ddf.explode("A")
4841 assert ddf.divisions == exploded_ddf.divisions
4842 assert_eq(exploded_ddf.compute(), exploded_df)
4843
4844
4845@pytest.mark.skip_with_pyarrow_strings # has to be array to explode

Callers

nothing calls this directly

Calls 4

explodeMethod · 0.95
assert_eqFunction · 0.90
explodeMethod · 0.45
computeMethod · 0.45

Tested by

no test coverage detected