Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:00:01

0001 #!/bin/bash
0002 function die { echo $1: status $2 ;  exit $2; }
0003 run="319176"
0004 dqmFile="/eos/cms/store/group/comm_dqm/DQMGUI_data/Run2018/ZeroBias/R0003191xx/DQM_V0001_R000319176__ZeroBias__Run2018B-PromptReco-v2__DQMIO.root"
0005 if [ ! -f "${dqmFile}" ]; then
0006   die "SKIPPING test, file ${dqmFile} not found" 0
0007 fi
0008 runStartTime=$( (python "${SCRAM_TEST_PATH}/cfg/getRunStartTime.py" "${run}" | tail -n1 ) || die "Failed to get run start time" $? )
0009 echo "DEBUG: Run ${run} started at ${runStartTime}"
0010 (cmsRun "${SCRAM_TEST_PATH}/cfg/makeMergeBadComponentPayload_example_cfg.py" globalTag=auto:run3_data_prompt runNumber="${run}"  runStartTime="${runStartTime}" dqmFile="${dqmFile}" dbfile="test.db" outputTag="TestBadComponents" ) || die "Failure running cmsRun makeMergeBadComponentPayload_example_cfg.py" $?
0011 # get the hash
0012 plEntryLn=$( (conddb --db sqlite_file:test.db list TestBadComponents | grep SiStripBadStrip) || die "Failed to get payload" $? )
0013 read -a plEntryLn_split <<< "${plEntryLn}"
0014 plHash="${plEntryLn_split[-2]}"
0015 (conddb --db sqlite_file:test.db dump "${plHash}" --format=xml -d test_dump.log ) || die "Could not dump test payload" $?
0016 (conddb dump 750b6c7049ccd4d2448944b22c2d4d16bf9cc30c --format=xml -d ref_dump.log ) || die "Could not dump reference payload" $?  # from SiStripBadComponents_2018_forSpecialBetaRun_v0_mc
0017 (diff -u ref_dump.log test_dump.log ) || die "Different payloads" $?