summaryrefslogtreecommitdiff
path: root/ext/pgsql/tests/02connection.phpt
diff options
context:
space:
mode:
authorMarcus Boerger <helly@php.net>2003-05-20 00:14:46 +0000
committerMarcus Boerger <helly@php.net>2003-05-20 00:14:46 +0000
commitdaded6e633a57a499a11fb97e417d063cc803058 (patch)
tree0911a0c4dba0091bbfde6fc4a1bafbd55e8c1291 /ext/pgsql/tests/02connection.phpt
parent4a113728053fdd17c8ab59f323c7d62881f087a1 (diff)
downloadphp-git-daded6e633a57a499a11fb97e417d063cc803058.tar.gz
Reorganized tests
Diffstat (limited to 'ext/pgsql/tests/02connection.phpt')
-rw-r--r--ext/pgsql/tests/02connection.phpt42
1 files changed, 41 insertions, 1 deletions
diff --git a/ext/pgsql/tests/02connection.phpt b/ext/pgsql/tests/02connection.phpt
index fd1333dfe6..f1258f6df1 100644
--- a/ext/pgsql/tests/02connection.phpt
+++ b/ext/pgsql/tests/02connection.phpt
@@ -4,7 +4,47 @@ PostgreSQL connection
<?php include("skipif.inc"); ?>
--FILE--
<?php
-include("connection.inc");
+// connection function tests
+
+include('config.inc');
+
+$db = pg_pconnect($conn_str);
+if (pg_connection_status($db) != PGSQL_CONNECTION_OK)
+{
+ echo "pg_connection_status() error\n";
+}
+if (!pg_connection_reset($db))
+{
+ echo "pg_connection_reset() error\n";
+}
+if (pg_connection_busy($db))
+{
+ echo "pg_connection_busy() error\n";
+}
+if (!pg_host($db))
+{
+ echo "pg_host() error\n";
+}
+if (!pg_dbname($db))
+{
+ echo "pg_dbname() error\n";
+}
+if (!pg_port($db))
+{
+ echo "pg_port() error\n";
+}
+if (pg_tty($db))
+{
+ echo "pg_tty() error\n";
+}
+if (pg_options($db))
+{
+ echo "pg_options() error\n";
+}
+
+pg_close($db);
+
+echo "OK";
?>
--EXPECT--
OK