Skip to content

Commit

Permalink
xfail cudf argmin / argmax (#1599)
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcoGorelli authored Dec 15, 2024
1 parent 30ff0b8 commit 3a3de10
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/expr_and_series/arg_max_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ def test_expr_arg_max_expr(
if "modin" in str(constructor):
# TODO(unassigned): bug in modin?
return
if "cudf" in str(constructor):
# not implemented yet
request.applymarker(pytest.mark.xfail)
df = nw.from_native(constructor(data))
df = nw.maybe_set_index(df, "i")
result = df.select(nw.col("a", "b", "z").arg_max())
Expand All @@ -31,10 +34,14 @@ def test_expr_arg_max_series(
constructor_eager: ConstructorEager,
col: str,
expected: float,
request: pytest.FixtureRequest,
) -> None:
if "modin" in str(constructor_eager):
# TODO(unassigned): bug in modin?
return
if "cudf" in str(constructor_eager):
# not implemented yet
request.applymarker(pytest.mark.xfail)
series = nw.from_native(constructor_eager(data), eager_only=True)[col]
series = nw.maybe_set_index(series, index=[1, 0, 9]) # type: ignore[arg-type]
result = series.arg_max()
Expand Down
7 changes: 7 additions & 0 deletions tests/expr_and_series/arg_min_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ def test_expr_arg_min_expr(
if "dask" in str(constructor):
# This operation is row-order dependent so we don't support it for Dask
request.applymarker(pytest.mark.xfail)
if "cudf" in str(constructor):
# not implemented yet
request.applymarker(pytest.mark.xfail)
df = nw.from_native(constructor(data))
result = df.select(nw.col("a", "b", "z").arg_min())
expected = {"a": [0], "b": [0], "z": [0]}
Expand All @@ -27,10 +30,14 @@ def test_expr_arg_min_series(
constructor_eager: ConstructorEager,
col: str,
expected: float,
request: pytest.FixtureRequest,
) -> None:
if "modin" in str(constructor_eager):
# TODO(unassigned): bug in modin?
return
if "cudf" in str(constructor_eager):
# not implemented yet
request.applymarker(pytest.mark.xfail)
series = nw.from_native(constructor_eager(data), eager_only=True)[col]
series = nw.maybe_set_index(series, index=[1, 0, 9]) # type: ignore[arg-type]
result = series.arg_min()
Expand Down

0 comments on commit 3a3de10

Please sign in to comment.