Skip to content
This repository was archived by the owner on Apr 1, 2026. It is now read-only.

Commit 63b13f2

Browse files
committed
test
1 parent 8c4a8fc commit 63b13f2

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

tests/system/large/bigquery/test_ai.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,3 +111,20 @@ def test_generate_table(text_model):
111111
assert "creator" in result.columns
112112
# The model may not always return the exact number of rows requested.
113113
assert len(result) > 0
114+
115+
116+
def test_generate_table_with_mapping_schema(text_model):
117+
df = bpd.DataFrame(
118+
{"prompt": ["Generate a table of 2 programming languages and their creators."]}
119+
)
120+
121+
result = ai.generate_table(
122+
text_model,
123+
df,
124+
output_schema={"language": "STRING", "creator": "STRING"},
125+
)
126+
127+
assert "language" in result.columns
128+
assert "creator" in result.columns
129+
# The model may not always return the exact number of rows requested.
130+
assert len(result) > 0

0 commit comments

Comments
 (0)