From d0111d785df10de3eacf41716aff27e579ab67e8 Mon Sep 17 00:00:00 2001 From: George Peter Banyard Date: Sun, 13 Sep 2020 05:31:01 +0200 Subject: Promote warnings to Errors in PostgreSQL extension Do some drive by indentation fixes Also fix pg_select() in regards to the $result_type arg which was missing from ZPP Closes GH-6129 --- ext/pgsql/tests/pg_insert_002.phpt | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'ext/pgsql/tests/pg_insert_002.phpt') 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) -- cgit v1.2.1