diff options
Diffstat (limited to 'ext/pgsql/tests/10pg_convert_85.phpt')
-rw-r--r-- | ext/pgsql/tests/10pg_convert_85.phpt | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/ext/pgsql/tests/10pg_convert_85.phpt b/ext/pgsql/tests/10pg_convert_85.phpt new file mode 100644 index 0000000..4f1c92b --- /dev/null +++ b/ext/pgsql/tests/10pg_convert_85.phpt @@ -0,0 +1,29 @@ +--TEST-- +PostgreSQL pg_convert() (8.5+) +--SKIPIF-- +<?php +include("skipif.inc"); +skip_server_version('8.5dev', '<'); +?> +--FILE-- +<?php +error_reporting(E_ALL); + +include 'config.inc'; + +$db = pg_connect($conn_str); + +$fields = array('num'=>'1234', 'str'=>'AAA', 'bin'=>'BBB'); +$converted = pg_convert($db, $table_name, $fields); + +var_dump($converted); +?> +--EXPECT-- +array(3) { + ["num"]=> + string(4) "1234" + ["str"]=> + string(5) "'AAA'" + ["bin"]=> + string(11) "'\\x424242'" +} |