Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions tests/unit/test_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -1509,6 +1509,15 @@ def test_eq_with_non_table_returns_false(

assert result is False

def test_eq_returns_not_implemented_for_non_table(
self, make_table: "Callable[..., Table]"
) -> None:
table = make_table()

result = table.__eq__("string")

assert result is NotImplemented

def test_equal_relative_vs_absolute_path(
self, tmp_path: "Path", monkeypatch: "pytest.MonkeyPatch"
) -> None:
Expand Down
12 changes: 12 additions & 0 deletions tests/unit/test_transaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -1393,6 +1393,18 @@ def test_eq_with_non_transaction_returns_false(
finally:
tx.abort()

def test_eq_returns_not_implemented_for_non_transaction(
self, make_table: "Callable[..., Table]"
) -> None:
table = make_table()

tx = table.transaction()
try:
result = tx.__eq__("string")
assert result is NotImplemented
finally:
tx.abort()

def test_finalized_vs_active_not_equal(self, tmp_path: "Path") -> None:
path1 = tmp_path / "test1.jsonlt"
path2 = tmp_path / "test2.jsonlt"
Expand Down