Skip to content

Commit 187250a

Browse files
test: Fix integration tests (#228)
1 parent 038d8da commit 187250a

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

tests/integration/dbapi/async/test_queries_async.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,6 @@ async def test_select(
130130
) -> None:
131131
"""Select handles all data types properly."""
132132
with connection.cursor() as c:
133-
assert (await c.execute("set firebolt_use_decimal = 1")) == -1
134133
assert await c.execute(all_types_query) == 1, "Invalid row count returned"
135134
assert c.rowcount == 1, "Invalid rowcount value"
136135
data = await c.fetchall()
@@ -310,7 +309,6 @@ async def test_empty_query(c: Cursor, query: str, params: tuple) -> None:
310309
await c.fetchall()
311310

312311
with connection.cursor() as c:
313-
await c.execute("set firebolt_use_decimal = 1")
314312
await c.execute("DROP TABLE IF EXISTS test_tb_async_parameterized")
315313
await c.execute(
316314
"CREATE FACT TABLE test_tb_async_parameterized(i int, f float, s string, sn"

tests/integration/dbapi/sync/test_queries.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ def test_select(
8989
) -> None:
9090
"""Select handles all data types properly."""
9191
with connection.cursor() as c:
92-
assert c.execute("set firebolt_use_decimal = 1") == -1
9392
assert c.execute(all_types_query) == 1, "Invalid row count returned"
9493
assert c.rowcount == 1, "Invalid rowcount value"
9594
data = c.fetchall()
@@ -263,7 +262,6 @@ def test_empty_query(c: Cursor, query: str, params: tuple) -> None:
263262
c.fetchall()
264263

265264
with connection.cursor() as c:
266-
c.execute("set firebolt_use_decimal = 1")
267265
c.execute("DROP TABLE IF EXISTS test_tb_parameterized")
268266
c.execute(
269267
"CREATE FACT TABLE test_tb_parameterized(i int, f float, s string, sn"

tests/integration/dbapi/sync/test_system_engine.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ def db_specs(region, attached_engine):
6868

6969
@mark.parametrize(
7070
"query",
71-
["SELECT 1", "CREATE DIMENSION TABLE dummy(id INT)", "SHOW TABLES", "SHOW INDEXES"],
71+
["CREATE DIMENSION TABLE dummy(id INT)", "SHOW TABLES", "SHOW INDEXES"],
7272
)
7373
def test_query_errors(connection_system_engine, query):
7474
with connection_system_engine.cursor() as cursor:
@@ -137,3 +137,10 @@ def check_engine_status(cursor, engine_name, status):
137137
check_engine_status(cursor, engine_name, "Running")
138138
cursor.execute(f"STOP ENGINE {engine_name}")
139139
check_engine_status(cursor, engine_name, "Stopped")
140+
141+
142+
@mark.xdist_group(name="system_engine")
143+
def test_select_one(connection_system_engine):
144+
"""SELECT statements are supported"""
145+
with connection_system_engine.cursor() as cursor:
146+
cursor.execute("SELECT 1")

0 commit comments

Comments
 (0)