Skip to content

Commit

Permalink
test: Use compare dicts in is_duplicated_test (#809)
Browse files Browse the repository at this point in the history
  • Loading branch information
thomasjpfan authored Aug 18, 2024
1 parent aa7fb3e commit 1a7e282
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions tests/expr_and_series/is_duplicated_test.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from typing import Any

import numpy as np
import pytest

import narwhals.stable.v1 as nw
Expand Down Expand Up @@ -28,5 +27,5 @@ def test_is_duplicated_expr(constructor: Any, request: Any) -> None:
def test_is_duplicated_series(constructor_eager: Any) -> None:
series = nw.from_native(constructor_eager(data), eager_only=True)["a"]
result = series.is_duplicated()
expected = np.array([True, True, False])
assert (result.to_numpy() == expected).all()
expected = {"a": [True, True, False]}
compare_dicts({"a": result}, expected)

0 comments on commit 1a7e282

Please sign in to comment.