Skip to content

Commit dbff7d8

Browse files
committed
fix(ibis): fixed test models
1 parent 7bcce3b commit dbff7d8

18 files changed

+26
-26
lines changed

ibis-server/app/model/metadata/bigquery.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ def get_table(row) -> Table:
7676
catalog=row["table_catalog"],
7777
table=row["table_name"],
7878
),
79-
primaryKey="",
79+
primaryKey=[],
8080
)
8181

8282
def is_root_column(row) -> bool:

ibis-server/app/model/metadata/canner.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@ def _build_table(cls, data: dict) -> Table:
166166
name=data["sqlName"],
167167
description=data["dataMetadata"]["metadata"]["description"],
168168
columns=cls._build_columns(data["columns"]),
169-
primaryKey="",
169+
primaryKey=[],
170170
properties=(
171171
TableProperties(
172172
catalog="canner",

ibis-server/app/model/metadata/snowflake.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ def get_table_list(self) -> list[Table]:
5858
catalog=row["TABLE_CATALOG"],
5959
table=row["TABLE_NAME"],
6060
),
61-
primaryKey="",
61+
primaryKey=[],
6262
)
6363

6464
# table exists, and add column to the table

ibis-server/tests/routers/v2/connector/test_canner.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"type": "timestamp",
6767
},
6868
],
69-
"primaryKey": "orderkey",
69+
"primaryKey": ["orderkey"],
7070
},
7171
],
7272
}

ibis-server/tests/routers/v2/connector/test_gcs_file.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"type": "varchar",
4242
},
4343
],
44-
"primaryKey": "orderkey",
44+
"primaryKey": ["orderkey"],
4545
},
4646
{
4747
"name": "Customer",
@@ -66,7 +66,7 @@
6666
"expression": "sum(orders.totalprice)",
6767
},
6868
],
69-
"primaryKey": "custkey",
69+
"primaryKey": ["custkey"],
7070
},
7171
],
7272
"relationships": [

ibis-server/tests/routers/v2/connector/test_local_file.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"type": "varchar",
3737
},
3838
],
39-
"primaryKey": "orderkey",
39+
"primaryKey": ["orderkey"],
4040
},
4141
{
4242
"name": "Customer",
@@ -61,7 +61,7 @@
6161
"expression": "sum(orders.totalprice)",
6262
},
6363
],
64-
"primaryKey": "custkey",
64+
"primaryKey": ["custkey"],
6565
},
6666
],
6767
"relationships": [

ibis-server/tests/routers/v2/connector/test_minio_file.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
"type": "varchar",
4040
},
4141
],
42-
"primaryKey": "orderkey",
42+
"primaryKey": ["orderkey"],
4343
},
4444
{
4545
"name": "Customer",
@@ -64,7 +64,7 @@
6464
"expression": "sum(orders.totalprice)",
6565
},
6666
],
67-
"primaryKey": "custkey",
67+
"primaryKey": ["custkey"],
6868
},
6969
],
7070
"relationships": [

ibis-server/tests/routers/v2/connector/test_mssql.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
"type": "bytea",
6363
},
6464
],
65-
"primaryKey": "orderkey",
65+
"primaryKey": ["orderkey"],
6666
},
6767
],
6868
}

ibis-server/tests/routers/v2/connector/test_mysql.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"type": "bytea",
6565
},
6666
],
67-
"primaryKey": "orderkey",
67+
"primaryKey": ["orderkey"],
6868
},
6969
{
7070
"name": "Customer",
@@ -73,7 +73,7 @@
7373
{"name": "custkey", "expression": "c_custkey", "type": "integer"},
7474
{"name": "name", "expression": "c_name", "type": "varchar"},
7575
],
76-
"primaryKey": "custkey",
76+
"primaryKey": ["custkey"],
7777
},
7878
],
7979
}

ibis-server/tests/routers/v2/connector/test_oracle.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
"type": "blob",
7272
},
7373
],
74-
"primaryKey": "orderkey",
74+
"primaryKey": ["orderkey"],
7575
}
7676
],
7777
}

ibis-server/tests/routers/v2/connector/test_postgres.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
"type": "bytea",
6767
},
6868
],
69-
"primaryKey": "orderkey",
69+
"primaryKey": ["orderkey"],
7070
},
7171
{
7272
"name": "Customer",

ibis-server/tests/routers/v2/connector/test_s3_file.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"type": "varchar",
4242
},
4343
],
44-
"primaryKey": "orderkey",
44+
"primaryKey": ["orderkey"],
4545
},
4646
{
4747
"name": "Customer",
@@ -66,7 +66,7 @@
6666
"expression": "sum(orders.totalprice)",
6767
},
6868
],
69-
"primaryKey": "custkey",
69+
"primaryKey": ["custkey"],
7070
},
7171
],
7272
"relationships": [

ibis-server/tests/routers/v2/connector/test_snowflake.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
"type": "timestamp",
6262
},
6363
],
64-
"primaryKey": "orderkey",
64+
"primaryKey": ["orderkey"],
6565
},
6666
],
6767
}

ibis-server/tests/routers/v2/test_analysis.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
{"name": "mktsegment", "expression": "mktsegment", "type": "varchar"},
2121
{"name": "comment", "expression": "comment", "type": "varchar"},
2222
],
23-
"primaryKey": "custkey",
23+
"primaryKey": ["custkey"],
2424
},
2525
{
2626
"name": "orders",
@@ -44,7 +44,7 @@
4444
},
4545
{"name": "comment", "expression": "comment", "type": "varchar"},
4646
],
47-
"primaryKey": "orderkey",
47+
"primaryKey": ["orderkey"],
4848
},
4949
{
5050
"name": "lineitem",

ibis-server/tests/routers/v2/test_relationship_valid.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
{"name": "id", "type": "integer"},
1818
{"name": "many_col", "type": "integer"},
1919
],
20-
"primaryKey": "id",
20+
"primaryKey": ["id"],
2121
},
2222
{
2323
"name": "t2",

ibis-server/tests/routers/v3/connector/bigquery/test_query.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
"type": "timestamptz",
5454
},
5555
],
56-
"primaryKey": "o_orderkey",
56+
"primaryKey": ["o_orderkey"],
5757
},
5858
],
5959
}

ibis-server/tests/routers/v3/connector/local_file/test_query.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
},
3030
{"name": "orderdate", "expression": "o_orderdate", "type": "date"},
3131
],
32-
"primaryKey": "orderkey",
32+
"primaryKey": ["orderkey"],
3333
},
3434
{
3535
"name": "Customer",
@@ -54,7 +54,7 @@
5454
"expression": 'sum("Orders".totalprice)',
5555
},
5656
],
57-
"primaryKey": "custkey",
57+
"primaryKey": ["custkey"],
5858
},
5959
],
6060
"relationships": [

ibis-server/tests/routers/v3/connector/postgres/test_query.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
"type": "timestamptz",
6060
},
6161
],
62-
"primaryKey": "o_orderkey",
62+
"primaryKey": ["o_orderkey"],
6363
},
6464
{
6565
"name": "customer",
@@ -78,7 +78,7 @@
7878
"expression": "sum(orders.o_totalprice_double)",
7979
},
8080
],
81-
"primaryKey": "c_custkey",
81+
"primaryKey": ["c_custkey"],
8282
},
8383
],
8484
"relationships": [

0 commit comments

Comments
 (0)