MCPcopy Index your code
hub / github.com/pathwaycom/pathway / test_having_2

Function test_having_2

python/pathway/tests/test_column_properties.py:459–475  ·  view source on GitHub ↗
(append_only_1, append_only_2, append_only_3)

Source from the content-addressed store, hash-verified

457@pytest.mark.parametrize("append_only_2", [True, False])
458@pytest.mark.parametrize("append_only_3", [True, False])
459def test_having_2(append_only_1, append_only_2, append_only_3):
460 class Schema1(pw.Schema):
461 a: int = pw.column_definition(append_only=append_only_1)
462 b: int = pw.column_definition(append_only=append_only_2)
463
464 class Schema2(pw.Schema, append_only=append_only_3):
465 c: int
466
467 table_1 = table_from_datasource(TestDataSource(schema=Schema1))
468 table_2 = table_from_datasource(TestDataSource(schema=Schema2))
469 result = table_1._having(table_2.id)
470
471 assert result._id_column.properties.append_only == (
472 (append_only_1 or append_only_2) and append_only_3
473 )
474 assert result.a._column.properties.append_only == (append_only_1 and append_only_3)
475 assert result.b._column.properties.append_only == (append_only_2 and append_only_3)
476
477
478@pytest.mark.parametrize("append_only_1", [True, False])

Callers

nothing calls this directly

Calls 3

table_from_datasourceFunction · 0.90
TestDataSourceClass · 0.90
_havingMethod · 0.80

Tested by

no test coverage detected