Warning, /CondFormats/HcalObjects/test/runHcalPayloadsTest is written in an unsupported language. File is not indexed.
0001 # tests all classes in a packages
0002 setenv SCRAM_ARCH slc5_amd64_gcc434
0003
0004 set testsourcedir=CondFormats/HcalObjects/test
0005 set templatecc=testHcalPayloadIO.cc
0006
0007 cmsenv
0008 cd $CMSSW_BASE/src
0009 rm -rf $CMSSW_BASE/src/PayloadTest
0010 mkdir -p $CMSSW_BASE/src/PayloadTest/PayloadTest/test
0011 cd $CMSSW_BASE/src/PayloadTest/PayloadTest/test
0012 cp $CMSSW_BASE/src/${testsourcedir}/${templatecc} .
0013
0014
0015 set pack=$CMSSW_BASE/src/CondFormats/HcalObjects
0016 echo "testing package $pack"
0017
0018 foreach class (`grep "class_version" $pack/src/classes_def.xml | sed 's/[^"]*"//' | sed 's/".*//'`)
0019 set cname=`echo "$class" | sed 's/[<,:, ,>]/_/g'`
0020 echo ${cname}
0021 set currentdir=`pwd`
0022 echo ${currentdir}
0023 #/bin/rm -f ${currentdir}/${cname}_test.cc
0024 echo "#define ALLCLASSES" > ${cname}_test.cc
0025 cat testHcalPayloadIO.cc >> ${cname}_test.cc
0026 sed -i "s/THECLASS/$class/g" ${cname}_test.cc
0027 sed -i "s/THEPACKAGE/HcalObjects/g" ${cname}_test.cc
0028 #/bin/rm -f ${currentdir}/bfile
0029 echo "<bin file="'"'"${cname}_test.cc"'"'" name="'"'"CondPayload_${cname}_testIO"'">' > bfile
0030 echo "<use name="'"'"CondFormats/HcalObjects"'"/>' >> bfile
0031 echo "<use name="'"'"CondCore/DBCommon"'"/>' >> bfile
0032 echo "</bin>" >> bfile
0033 mv bfile BuildFile.xml
0034 scramv1 b
0035 echo "run CondPayload_${cname}_testIO"
0036 $CMSSW_BASE/test/$SCRAM_ARCH/CondPayload_${cname}_testIO
0037
0038 ora_database_manager -c sqlite_file:test.db -list
0039 ora_database_manager -c sqlite_file:test.db -lm -cv -cn ${cname}
0040 ora_database_manager -c sqlite_file:test.db -dm -mv ${cname}_M000 -f ${cname}_mapping.xml
0041 cat ${cname}_mapping.xml
0042 end
0043