Skip to content

Commit

Permalink
Fix copy tests for PostgreSQL 16
Browse files Browse the repository at this point in the history
PostgreSQL 16 converted a few datatype input functions to use "soft" error
reporting. This changed the function name and the tests checking for execptions
in this function have to be adjusted.
  • Loading branch information
AlexanderS authored and tlocke committed Nov 13, 2023
1 parent c662f40 commit a2dc1e8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion test/dbapi/test_copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def test_copy_from_with_error(db_table):
),
"W": ('COPY t1, line 2, column f1: ""',),
"F": ("numutils.c",),
"R": ("pg_atoi", "pg_strtoint32"),
"R": ("pg_atoi", "pg_strtoint32", "pg_strtoint32_safe"),
}
earg = e.value.args[0]
for k, v in arg.items():
Expand Down
2 changes: 1 addition & 1 deletion test/legacy/test_copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def test_copy_from_with_error(db_table):
),
"W": ('COPY t1, line 2, column f1: ""',),
"F": ("numutils.c",),
"R": ("pg_atoi", "pg_strtoint32"),
"R": ("pg_atoi", "pg_strtoint32", "pg_strtoint32_safe"),
}
earg = e.value.args[0]
for k, v in arg.items():
Expand Down
2 changes: 1 addition & 1 deletion test/native/test_copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def test_copy_from_with_error(db_table):
),
"W": ('COPY t1, line 2, column f1: ""',),
"F": ("numutils.c",),
"R": ("pg_atoi", "pg_strtoint32"),
"R": ("pg_atoi", "pg_strtoint32", "pg_strtoint32_safe"),
}
earg = e.value.args[0]
for k, v in arg.items():
Expand Down

0 comments on commit a2dc1e8

Please sign in to comment.