summaryrefslogtreecommitdiff
path: root/ext/pgsql/tests/pg_insert_002.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/pgsql/tests/pg_insert_002.phpt')
-rw-r--r--ext/pgsql/tests/pg_insert_002.phpt9
1 files changed, 6 insertions, 3 deletions
diff --git a/ext/pgsql/tests/pg_insert_002.phpt b/ext/pgsql/tests/pg_insert_002.phpt
index bb84a00d0d..0aa6395cfa 100644
--- a/ext/pgsql/tests/pg_insert_002.phpt
+++ b/ext/pgsql/tests/pg_insert_002.phpt
@@ -10,13 +10,16 @@ include('config.inc');
$conn = pg_connect($conn_str);
foreach (array('', '.', '..') as $table) {
- var_dump(pg_insert($conn, $table, array('id' => 1, 'id2' => 1)));
+ try {
+ var_dump(pg_insert($conn, $table, array('id' => 1, 'id2' => 1)));
+ } catch (\ValueError $e) {
+ echo $e->getMessage() . \PHP_EOL;
+ }
}
?>
Done
--EXPECTF--
-Warning: pg_insert(): The table name must be specified in %s on line %d
-bool(false)
+pg_insert(): Argument #2 ($table_name) cannot be empty
Warning: pg_insert(): The table name must be specified in %s on line %d
bool(false)