Index: trunk/Ohana/src/addstar/test/simple.dvo
===================================================================
--- trunk/Ohana/src/addstar/test/simple.dvo	(revision 34260)
+++ trunk/Ohana/src/addstar/test/simple.dvo	(revision 34405)
@@ -4,4 +4,5 @@
 
 macro test.all
+  # test.fields (DVO schema) (CMF format)
   test.fields PS1_DEV_0 PS1_V1
   test.fields PS1_DEV_1 PS1_V1
@@ -9,4 +10,5 @@
   test.fields PS1_V2 	PS1_V1
   test.fields PS1_V3 	PS1_V1
+  test.fields PS1_V4 	PS1_V1
 
   test.fields PS1_DEV_0 PS1_V2
@@ -15,4 +17,5 @@
   test.fields PS1_V2 	PS1_V2
   test.fields PS1_V3 	PS1_V2
+  test.fields PS1_V4 	PS1_V4
 
   test.fields PS1_DEV_0 PS1_V3
@@ -21,4 +24,5 @@
   test.fields PS1_V2 	PS1_V3
   test.fields PS1_V3 	PS1_V3
+  test.fields PS1_V4 	PS1_V4
 
   test.fields PS1_DEV_0 PS1_V4
@@ -27,4 +31,5 @@
   test.fields PS1_V2 	PS1_V4
   test.fields PS1_V3 	PS1_V4
+  test.fields PS1_V4 	PS1_V4
 end  
 
@@ -36,5 +41,6 @@
   end
 
-  tapPLAN 51
+  echo ""
+  echo "testing --- CMF = $1, DVO = $2 ---"
 
   exec rm -rf catdir.test
@@ -45,7 +51,14 @@
   mkinput
   exec mkcmf test.in.txt test.cmf -date 2008/1/1 -time 01:00:00 -radec $RA $DEC -type $1
-  exec addstar -D CATDIR catdir.test -D CAMERA simtest test.cmf -D CATFORMAT $2 -quick-airmass
+  if ($TAP_VERBOSE)
+    exec addstar -D CATDIR catdir.test -D CAMERA simtest test.cmf -D CATFORMAT $2 -quick-airmass
+  else
+    exec addstar -D CATDIR catdir.test -D CAMERA simtest test.cmf -D CATFORMAT $2 -quick-airmass >& tmp.log
+  end
 
   list testfields -copy testfields_$1
+
+  # set the number of tests based on the testfields list
+  tapPLAN {3 + 3*($testfields:n - 1)}
 
   catdir catdir.test
@@ -77,6 +90,12 @@
   for i 1 $testfields:n
     list name -split $testfields:$i
-    if ("$name:0" == "SKIP") continue
-    if ("$name:2" == "SKIP") continue
+    if ("$name:0" == "SKIP") 
+      tapSKIP 3
+      continue
+    end
+    if ("$name:2" == "SKIP") 
+      tapSKIP 3
+      continue
+    end
     # must be the same length
     set v1 = $name:0
@@ -106,5 +125,5 @@
     # THETA is stored to only (360/65536) deg accuracy
     if ("$name:0" == "PSF_THETA")
-      echo $MEAN
+      # echo $MEAN
       tapOK {abs($MEAN)  < 0.006} "$name:0 vs $name:2 (MEAN)"
       tapOK {abs($SIGMA) < 0.001} "$name:0 vs $name:2 (SIGMA)"
@@ -304,2 +323,52 @@
   N_FRAMES          : SKIP # not ingested into DVO
 end
+
+# this list is good for PS1_V4
+list testfields_PS1_V4
+  IPP_IDET          : detid	
+  X_PSF             : xccd	
+  Y_PSF             : yccd	
+  X_PSF_SIG         : xccd:err # FAIL
+  Y_PSF_SIG         : yccd:err # FAIL
+  POSANGLE          : SKIP # astrometry is not calibrated in the cmf
+  PLTSCALE          : SKIP # astrometry is not calibrated in the cmf
+  PSF_INST_MAG      : mag:inst	
+  PSF_INST_MAG_SIG  : mag:err	
+  PSF_INST_FLUX     : SKIP # not ingested into DVO
+  PSF_INST_FLUX_SIG : SKIP # not ingested into DVO
+  AP_MAG_STANDARD   : mag:aperinst # FAIL
+  AP_MAG_RAW        : SKIP # not ingested into DVO
+  AP_MAG_RADIUS     : SKIP # not ingested into DVO
+  CAL_PSF_MAG       : SKIP # photometry is not calibrated in the cmf
+  CAL_PSF_MAG_SIG   : SKIP # photometry is not calibrated in the cmf
+  RA_PSF            : SKIP # astrometry is not calibrated in the cmf
+  DEC_PSF           : SKIP # astrometry is not calibrated in the cmf
+  PEAK_FLUX_AS_MAG  : SKIP # not ingested into DVO
+  SKY               : sky	
+  SKY_SIG           : sky_err	
+  PSF_CHISQ         : psf_chisq	
+  CR_NSIGMA         : cr_nsigma	
+  EXT_NSIGMA        : ext_nsigma
+  PSF_MAJOR         : FWHM_MAJ	
+  PSF_MINOR         : FWHM_MIN	
+  PSF_THETA         : THETA # FAIL
+  PSF_QF            : PSF_QF	
+  PSF_QF_PERFECT    : SKIP # not ingested into DVO
+  PSF_NDOF          : PSF_NDOF
+  PSF_NPIX          : PSF_NPIX
+  MOMENTS_XX        : MXX
+  MOMENTS_XY        : MXY
+  MOMENTS_YY        : MYY
+  MOMENTS_M3C       : SKIP # not ingested into DVO
+  MOMENTS_M3S       : SKIP # not ingested into DVO
+  MOMENTS_M4C       : SKIP # not ingested into DVO
+  MOMENTS_M4S       : SKIP # not ingested into DVO
+  MOMENTS_R1        : SKIP # not ingested into DVO
+  MOMENTS_RH        : SKIP # not ingested into DVO
+  KRON_FLUX         : mag:kroninst
+  KRON_FLUX_ERR     : mag:kronerr
+  KRON_FLUX_INNER   : SKIP # not ingested into DVO
+  KRON_FLUX_OUTER   : SKIP # not ingested into DVO
+  FLAGS             : phot_flags
+  N_FRAMES          : SKIP # not ingested into DVO
+end
