Index: trunk/psLib/test/dataIO/tst_psDB.c
===================================================================
--- trunk/psLib/test/dataIO/tst_psDB.c	(revision 4105)
+++ trunk/psLib/test/dataIO/tst_psDB.c	(revision 4257)
@@ -9,6 +9,6 @@
  *  @author Aaron Culliney, MHPCC
  *
- *  @version $Revision: 1.12 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2005-06-03 23:46:07 $
+ *  @version $Revision: 1.13 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2005-06-15 01:02:08 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -98,6 +98,5 @@
     psDB *dbh = NULL;
 
-    psLogMsg( __func__, PS_LOG_INFO, "initialize database connection...\n" );
-
+    // Initialize database connection with test database
     dbh = psDBInit(host, user, passwd, dbname);
     if (dbh == NULL) {
@@ -290,20 +289,30 @@
 }
 
-// Testpoint #XXX, initialize/break-down MySQL connection.
+// Testpoint #841, initialize/break-down MySQL connection.
 psS32 TPDBInit( void )
 {
-    psS32 failed = 0;
-    psDB *dbh = NULL;
-
-    psLogMsg( __func__, PS_LOG_INFO, "psDBInit/psDBCleanup shall initialize/cleanup database connection.\n" );
-
-    dbh = _init_psDB();
-    if (dbh == NULL) {
-        return 1;
-    }
-
-    psDBCleanup(dbh);
-
-    return failed;
+    psDB *dbh = NULL;
+
+    // Initialize database with valid arguments
+    dbh = _init_psDB();
+    if (dbh == NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Did not expect NULL to be returned for valid arguments");
+        return 1;
+    }
+
+    // Cleanup database/connection with valid psDB object
+    psDBCleanup(dbh);
+
+    // Attempt to initialize database with invalid arguments
+    dbh = psDBInit("xxx",NULL,NULL,NULL);
+    if(dbh != NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Did not expect non-NULL psDB with invalid arguments");
+        return 2;
+    }
+
+    // Attempt cleanup database/connection with NULL psDB object
+    psDBCleanup(NULL);
+
+    return 0;
 }
 
