MCPcopy Create free account
hub / github.com/It4innovations/hyperqueue / test_parse_tables_horizontal

Function test_parse_tables_horizontal

tests/test_utils.py:93–119  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

91
92
93def test_parse_tables_horizontal():
94 tables = parse_tables(
95 """+---------+--------------+
96| Id | Name |
97+---------+--------------+
98| a | b |
99| c | d |
100+---------+--------------+
101+---------+--------------+
102| Id | Name |
103+---------+--------------+
104| e | f |
105| g | h |
106+---------+--------------+
107"""
108 )
109 print("Found tables:", len(tables))
110 assert tables[0].header == ["Id", "Name"]
111 assert tables[0].rows == [
112 ["a", "b"],
113 ["c", "d"],
114 ]
115 assert tables[1].header == ["Id", "Name"]
116 assert tables[1].rows == [
117 ["e", "f"],
118 ["g", "h"],
119 ]
120
121
122def test_parse_tables_vertical():

Callers

nothing calls this directly

Calls 1

parse_tablesFunction · 0.85

Tested by

no test coverage detected