Skip to content

Commit

Permalink
fix: incorrect test!
Browse files Browse the repository at this point in the history
  • Loading branch information
agoose77 committed Dec 1, 2023
1 parent 91a16c5 commit ea53fe2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/awkward/contents/recordarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -1296,11 +1296,12 @@ def _is_equal_to(
) -> bool:
return (
self._is_equal_to_generic(other, all_parameters)
and set(self._fields) == set(other.fields)
and self.is_tuple == other.is_tuple
and set(self.fields) == set(other.fields)
and all(
content._is_equal_to(
other.content(field), index_dtype, numpyarray, all_parameters
)
for field, content in zip(self._fields, self._contents)
for field, content in zip(self.fields, self._contents)
)
)
4 changes: 2 additions & 2 deletions tests/test_2368_type_is_equal.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def test_record_tuple():
assert record_type != tuple_type


def test_record_mixed():
def test_record_permuted():
record = ak.types.from_datashape("10 * var * {x: int64, y: int32}")
permutation = ak.types.from_datashape("10 * var * {y: int64, x: int32}")
assert record == permutation
assert record != permutation

0 comments on commit ea53fe2

Please sign in to comment.