Index: /trunk/psLib/src/types/psArguments.h
===================================================================
--- /trunk/psLib/src/types/psArguments.h	(revision 6188)
+++ /trunk/psLib/src/types/psArguments.h	(revision 6189)
@@ -7,6 +7,6 @@
  *  @author David Robbins, MHPCC
  *
- *  @version $Revision: 1.1 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2006-01-23 23:52:15 $
+ *  @version $Revision: 1.2 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2006-01-25 03:02:47 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -28,5 +28,5 @@
  */
 int psArgumentVerbosity(
-    int *argc,                         ///< number or arguments
+    int *argc,                         ///< number of arguments
     char **argv                        ///< the argument list
 );
@@ -37,5 +37,5 @@
  */
 int psArgumentGet(
-    int argc,                          ///< number or arguments
+    int argc,                          ///< number of arguments
     char **argv,                       ///< the argument list
     const char *arg                    ///< the specified argument to match
@@ -50,5 +50,5 @@
 bool psArgumentRemove(
     int argnum,                        ///< the argument to remove
-    int *argc,                         ///< number or arguments
+    int *argc,                         ///< number of arguments
     char **argv                        ///< the argument list
 );
@@ -65,5 +65,5 @@
 bool psArgumentParse(
     psMetadata *arguments,             ///< metadata container for arguments
-    int *argc,                         ///< number or arguments
+    int *argc,                         ///< number of arguments
     char **argv                        ///< the argument list
 );
@@ -74,12 +74,20 @@
 );
 
+/** Sets the log level.
+ *
+ *  @return psS32:     the log level.
+ */
 psS32 psLogArguments(
-    int *argc,
-    char **argv
+    int *argc,                         ///< number of arguments
+    char **argv                        ///< the argument list
 );
 
+/** Sets trace levels by facility
+ *
+ *  @return psS32:      1 (true) if successful or else 2.
+ */
 psS32 psTraceArguments(
-    int *argc,
-    char **argv
+    int *argc,                         ///< number of arguments
+    char **argv                        ///< the argument list
 );
 
Index: /trunk/psLib/src/types/psMetadata.c
===================================================================
--- /trunk/psLib/src/types/psMetadata.c	(revision 6188)
+++ /trunk/psLib/src/types/psMetadata.c	(revision 6189)
@@ -12,6 +12,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.94 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2006-01-23 23:52:15 $
+ *  @version $Revision: 1.95 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2006-01-25 03:02:47 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -886,5 +886,5 @@
             *status = false;
         } else {
-            psError(PS_ERR_IO, true, "Couldn't find %s in the metadata.\n");
+            psError(PS_ERR_IO, true, "Couldn't find %s in the metadata.\n", key);
         }
     } else if (item->type != PS_DATA_METADATA) {
@@ -893,5 +893,5 @@
             *status = false;
         } else {
-            psLogMsg(__func__, PS_LOG_WARN, "%s isn't of type PS_DATA_META, as expected.\n");
+            psLogMsg(__func__, PS_LOG_WARN, "%s isn't of type PS_DATA_META, as expected.\n", key);
         }
         value = NULL;
@@ -921,5 +921,5 @@
             *status = false;
         } else {
-            psError(PS_ERR_IO, true, "Couldn't find %s in the metadata.\n");
+            psError(PS_ERR_IO, true, "Couldn't find %s in the metadata.\n", key);
         }
     } else if (item->type != PS_DATA_STRING) {
@@ -928,5 +928,5 @@
             *status = false;
         } else {
-            psLogMsg(__func__, PS_LOG_WARN, "%s isn't of type PS_DATA_STRING, as expected.\n");
+            psLogMsg(__func__, PS_LOG_WARN, "%s isn't of type PS_DATA_STRING, as expected.\n", key);
         }
         value = NULL;
Index: /trunk/psLib/src/types/psMetadataConfig.c
===================================================================
--- /trunk/psLib/src/types/psMetadataConfig.c	(revision 6188)
+++ /trunk/psLib/src/types/psMetadataConfig.c	(revision 6189)
@@ -10,6 +10,6 @@
 *  @author Eric Van Alst, MHPCC
 *
-*  @version $Revision: 1.49 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2005-12-24 00:33:20 $
+*  @version $Revision: 1.50 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2006-01-25 03:02:47 $
 *
 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -1417,5 +1417,5 @@
                 strncat(mdString, "F32 ", MAXSTR);
                 for (i = 0; ((psVector*)(item->data.V))->data.F32[i] != 0; i++) {
-                    snprintf(content, MAXSTR, "%f",
+                    snprintf(content, MAXSTR, "%22.15g",
                              ((psVector*)(item->data.V))->data.F32[i]);
                     if ( ((psVector*)(item->data.V))->data.F32[i+1] != 0 ) {
@@ -1428,5 +1428,5 @@
                 strncat(mdString, "F64 ", MAXSTR);
                 for (i = 0; ((psVector*)(item->data.V))->data.F64[i] != 0; i++) {
-                    snprintf(content, MAXSTR, "%lf",
+                    snprintf(content, MAXSTR, "%22.15g",
                              ((psVector*)(item->data.V))->data.F64[i]);
                     if ( ((psVector*)(item->data.V))->data.F64[i+1] != 0 ) {
Index: /trunk/psLib/test/astro/tst_psEarthOrientation.c
===================================================================
--- /trunk/psLib/test/astro/tst_psEarthOrientation.c	(revision 6188)
+++ /trunk/psLib/test/astro/tst_psEarthOrientation.c	(revision 6189)
@@ -5,6 +5,6 @@
 *  @author d-Rob, MHPCC
 *
-*  @version $Revision: 1.28 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2006-01-23 20:04:31 $
+*  @version $Revision: 1.29 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2006-01-25 03:02:47 $
 *
 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -305,4 +305,5 @@
     psEarthPole *pmodel = NULL;
     //Return NULL for NULL time input
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     pmodel = psEOC_PrecessionModel(empty);
     if (pmodel != NULL) {
@@ -312,4 +313,5 @@
     }
     //Return NULL for UT1 time input
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     psTime *UT1time = psTimeAlloc(PS_TIME_UT1);
     pmodel = psEOC_PrecessionModel(UT1time);
@@ -361,10 +363,10 @@
     time2->nsec = 0;
     time2->leapsecond = false;
-
-    //XXX:  MAY Be an Error here... Time for Precession Correction has to be TAI or seg faults
-    time2 = psTimeConvert(time2, PS_TIME_TAI);
+    //    time2 = psTimeConvert(time2, PS_TIME_TAI);
+
     //Tests for Precession Correction function//
     //Return NULL for NULL time input
     psEarthPole *pcorr = NULL;
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     pcorr = psEOC_PrecessionCorr(empty, PS_IERS_A);
     if (pcorr != NULL) {
@@ -375,4 +377,5 @@
 
     //Return NULL for Invalid IERS table
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     pcorr = psEOC_PrecessionCorr(time2, 3);
     if (pcorr != NULL) {
@@ -522,4 +525,5 @@
 
     //Return NULL for NULL input time
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     polarMotion = psEOC_GetPolarMotion(empty, PS_IERS_B);
     if (polarMotion != NULL) {
@@ -529,4 +533,5 @@
     }
     //Return NULL for incorrect Bulletin.
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     polarMotion = psEOC_GetPolarMotion(empty, 3);
     if (polarMotion != NULL) {
@@ -625,4 +630,6 @@
     psEarthPole *eop = NULL;
 
+    //Return NULL for NULL input time
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     eop = psEOC_PolarTideCorr(empty);
     if (eop != NULL) {
@@ -658,4 +665,5 @@
 
     //Return NULL for NULL input time.
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     nute = psEOC_NutationCorr(empty);
     if (nute != NULL) {
@@ -705,4 +713,5 @@
 
     //return NULL for NULL input time
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     rot = psSphereRot_TEOtoCEO(empty, NULL);
     if (rot != NULL) {
@@ -783,4 +792,6 @@
     q3 = -0.9999999897238481;
 
+    //Return NULL for NULL input earthpole
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     rot = psSphereRot_CEOtoGCRS(empty);
     if (rot != NULL) {
@@ -793,5 +804,5 @@
     if (rot == NULL) {
         psError(PS_ERR_BAD_PARAMETER_NULL, false,
-                "psSphereRot_CEOtoGCRS return NULL for valid psEarthPole input.\n");
+                "psSphereRot_CEOtoGCRS returned NULL for valid psEarthPole input.\n");
         return 2;
     }
@@ -857,4 +868,6 @@
     in->s = SEC_TO_RAD(in->s);
 
+    //Return NULL for NULL input earthpole
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate error message");
     rot = psSphereRot_ITRStoTEO(empty);
     if (rot != NULL) {
@@ -863,4 +876,5 @@
         return 1;
     }
+
     rot = psSphereRot_ITRStoTEO(in);
     if (rot == NULL) {
@@ -1050,32 +1064,69 @@
     psFree(rot);
 
-    // Invoke precess with invalid parameter
-    /*
-        psLogMsg(__func__,PS_LOG_INFO,"Following should generate an error message");
-        outputCoord = psSpherePrecess(inputCoord, fromTime, NULL);
-        if(outputCoord != NULL) {
-            psError(PS_ERR_UNKNOWN,true,"Did not return NULL with invalid input");
-            return 10;
-        }
-     
-        // Invoke precess with invalid parameter
-        psLogMsg(__func__,PS_LOG_INFO,"Following should generate an error message");
-        outputCoord = psSpherePrecess(inputCoord, NULL, toTime);
-        if(outputCoord != NULL) {
-            psError(PS_ERR_UNKNOWN,true,"Did not return NULL with invalid input");
-            return 11;
-        }
-    */
+    //Test other modes (IAU2000A, COMPLETE_[A,B])
+    // Set input coordinate
+    inputCoord->r = SPHERE_PRECESS_TP1_R;
+    inputCoord->d = SPHERE_PRECESS_TP1_D;
+    inputCoord->rErr = 0.0;
+    inputCoord->dErr = 0.0;
+    // Calculate precess
+    rot = psSpherePrecess(fromTime, toTime, PS_PRECESS_COMPLETE_A);
+    outputCoord = psSphereRotApply(NULL, rot, inputCoord);
+    if (outputCoord->r < -0.000001) {
+        outputCoord->r += 2.0 * M_PI;
+    }
+    // Verify return is not NULL
+    if(outputCoord == NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Returned NULL not expected");
+        return 10;
+    }
+    psFree(outputCoord);
+    psFree(rot);
+
+    rot = psSpherePrecess(fromTime, toTime, PS_PRECESS_COMPLETE_B);
+    outputCoord = psSphereRotApply(NULL, rot, inputCoord);
+    if (outputCoord->r < -0.000001) {
+        outputCoord->r += 2.0 * M_PI;
+    }
+    // Verify return is not NULL
+    if(outputCoord == NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Returned NULL not expected");
+        return 11;
+    }
+    psFree(outputCoord);
+    psFree(rot);
+
+    rot = psSpherePrecess(fromTime, toTime, PS_PRECESS_IAU2000A);
+    outputCoord = psSphereRotApply(NULL, rot, inputCoord);
+    if (outputCoord->r < -0.000001) {
+        outputCoord->r += 2.0 * M_PI;
+    }
+    // Verify return is not NULL
+    if(outputCoord == NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Returned NULL not expected");
+        return 12;
+    }
+    psFree(outputCoord);
+    psFree(rot);
+
     // Invoke precess with invalid parameter
     psLogMsg(__func__,PS_LOG_INFO,"Following should generate an error message");
     rot = psSpherePrecess(fromTime, toTime, 10);
-    //    outputCoord = psSpherePrecess(NULL, fromTime, toTime, PS_PRECESS_ROUGH);
     if(rot != NULL) {
-        //    if(outputCoord != NULL) {
         psError(PS_ERR_UNKNOWN,true,"Did not return NULL with invalid input");
+        return 14;
+    }
+    // Return NULL for NULL input times
+    psLogMsg(__func__,PS_LOG_INFO,"Following should generate an error message");
+    rot = psSpherePrecess(NULL, NULL, PS_PRECESS_ROUGH);
+    if(rot != NULL) {
+        psError(PS_ERR_UNKNOWN,true,"Did not return NULL with invalid input");
+        return 15;
+    }
+
+    if (!p_psEOCFinalize() ) {
+        psError(PS_ERR_BAD_PARAMETER_VALUE, false, "EOC failed finalization!\n");
         return 12;
     }
-    psFree(rot);
-
     // Free objects
     psFree(fromTime);
Index: /trunk/psLib/test/astro/tst_psSphereOps.c
===================================================================
--- /trunk/psLib/test/astro/tst_psSphereOps.c	(revision 6188)
+++ /trunk/psLib/test/astro/tst_psSphereOps.c	(revision 6189)
@@ -5,6 +5,6 @@
 *  @author d-Rob, MHPCC
 *
-*  @version $Revision: 1.15 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2006-01-18 23:49:06 $
+*  @version $Revision: 1.16 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2006-01-25 03:02:47 $
 *
 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -18,5 +18,4 @@
 static psS32 testSphereRotApply1(void);
 static psS32 testSphereRotApplyCelestial(void);
-//static psS32 testSphereRotPrecess(void);
 static psS32 testSphereOffset(void);
 
@@ -26,5 +25,4 @@
                               {testSphereRotApply1, 821, "psSphereRotApply()", 0, false},
                               {testSphereRotApplyCelestial, 822, "psSphereRotApplyCel()", 0, false},
-                              //                              {testSphereRotPrecess, 823, "psSphereRotPrecess()", 0, false},
                               {testSphereOffset, 825, "testSphereOffset()", 0, false},
                               {NULL}
