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

Function test_pipe

dask/dataframe/dask_expr/tests/test_collection.py:384–392  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

382
383
384def test_pipe():
385 df = pd.DataFrame({"x": range(50), "y": range(50, 100)})
386 ddf = from_pandas(df, npartitions=4)
387
388 def f(x, y, z=0):
389 return x + y + z
390
391 assert_eq(ddf.pipe(f, 1, z=2), f(ddf, 1, z=2))
392 assert_eq(ddf.x.pipe(f, 1, z=2), f(ddf.x, 1, z=2))
393
394
395def test_mode():

Callers

nothing calls this directly

Calls 4

from_pandasFunction · 0.90
assert_eqFunction · 0.90
pipeMethod · 0.80
fFunction · 0.70

Tested by

no test coverage detected