Skip to content

Commit 55fc1cc

Browse files
committed
Added tests for row_factory
Signed-off-by: chandr-andr (Kiselev Aleksandr) <chandr@chandr.net>
1 parent 2f22a81 commit 55fc1cc

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

python/tests/test_value_converter.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -582,7 +582,7 @@ async def test_row_factory_query_result(
582582
f"SELECT * FROM {table_name}",
583583
)
584584

585-
def row_factory(db_result: dict[str, Any]) -> list[str]:
585+
def row_factory(db_result: Dict[str, Any]) -> List[str]:
586586
return list(db_result.keys())
587587

588588
as_row_factory = select_result.row_factory(
@@ -596,14 +596,13 @@ def row_factory(db_result: dict[str, Any]) -> list[str]:
596596
async def test_row_factory_single_query_result(
597597
psql_pool: ConnectionPool,
598598
table_name: str,
599-
number_database_records: int,
600599
) -> None:
601600
connection = await psql_pool.connection()
602601
select_result = await connection.fetch_row(
603602
f"SELECT * FROM {table_name} LIMIT 1",
604603
)
605604

606-
def row_factory(db_result: dict[str, Any]) -> list[str]:
605+
def row_factory(db_result: Dict[str, Any]) -> List[str]:
607606
return list(db_result.keys())
608607

609608
as_row_factory = select_result.row_factory(

0 commit comments

Comments
 (0)