(op)
| 1434 | |
| 1435 | @pytest.mark.parametrize("op", [operator.lt, operator.le, operator.gt, operator.ge]) |
| 1436 | def test_tuples_none_cmp(op): |
| 1437 | table = T( |
| 1438 | """ |
| 1439 | a | b |
| 1440 | 1 | |
| 1441 | | |
| 1442 | 1 | 1 |
| 1443 | """ |
| 1444 | ).with_columns( |
| 1445 | x=pw.make_tuple(pw.this.a, pw.this.b), y=pw.make_tuple(pw.this.b, pw.this.a) |
| 1446 | ) |
| 1447 | |
| 1448 | with pytest.raises( |
| 1449 | TypeError, |
| 1450 | match=re.escape( |
| 1451 | f"Pathway does not support using binary operator {op.__name__} on columns " |
| 1452 | "of types tuple[int | None, int | None], tuple[int | None, int | None].", |
| 1453 | ), |
| 1454 | ): |
| 1455 | table.select(z=op(pw.this.x, pw.this.y)) |
| 1456 | |
| 1457 | |
| 1458 | def test_and_or_are_lazy(): |
nothing calls this directly
no test coverage detected