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

Function test_table_from_rows_stream

python/pathway/tests/test_utils.py:582–602  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

580
581
582def test_table_from_rows_stream():
583 class TestSchema(pw.Schema):
584 foo: int = pw.column_definition(primary_key=True)
585 bar: int
586
587 rows = [
588 (1, 2, 2, 1),
589 (1, 2, 4, -1),
590 (1, 3, 4, 1),
591 (4, 2, 4, 1),
592 ]
593 expected = T(
594 """
595 foo | bar
596 1 | 3
597 4 | 2
598 """
599 ).with_id_from(pw.this.foo)
600
601 table = pw.debug.table_from_rows(schema=TestSchema, rows=rows, is_stream=True)
602 assert_table_equality(table, expected)
603
604
605def test_table_from_rows():

Callers

nothing calls this directly

Calls 2

TFunction · 0.90
with_id_fromMethod · 0.80

Tested by

no test coverage detected