Skip to content

Commit

Permalink
Make sure to actually enter the event loop in the DelphesROOT_EDM4HEP…
Browse files Browse the repository at this point in the history
… executable (#125)

* Make sure to not abort event loop early

* Move tests to one branch

* Add test to make sure DelphesROOT_EDM4HEP works as expected

* Make sure to make tests runnable concurrently
  • Loading branch information
tmadlener authored Jul 29, 2024
1 parent efe646e commit 02a602e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 10 deletions.
2 changes: 1 addition & 1 deletion standalone/src/DelphesRootReader.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ class DelphesRootReader : public DelphesInputReader {
}
++m_entry;

return finished();
return true;
};

TTree* converterTree() override { return m_treeWriter->GetTree(); }
Expand Down
10 changes: 2 additions & 8 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,11 @@ find_file(DELPHES_CARD delphes_card_IDEA.tcl PATHS ${DELPHES_CARDS_DIR})
if(DELPHES_CARD)
if(BUILD_PYTHIA_READER)
ADD_COMPARISON_TEST(PythiaConverter_ee_Z_bbbar DelphesPythia8_EDM4HEP ${DELPHES_CARD} ${OUTPUT_CONFIG} pythia_converter_output_ee_Z_bbbar.root ${PROJECT_SOURCE_DIR}/examples/data/ee_Z_bbbar_ecm91GeV.cmd)
endif()
else()
message(WARNING "Cannot find IDEA delphes card from the delphes installation. Cannot use it for testing")
endif()

#Use tester card for testing the ResonanceDecayUserHook
find_file(DELPHES_CARD delphes_card_IDEA.tcl PATHS ${DELPHES_CARDS_DIR})
if(DELPHES_CARD)
if(BUILD_PYTHIA_READER)
ADD_COMPARISON_TEST(PythiaResonanceDecayFilter_pp_hhbbyy DelphesPythia8_EDM4HEP ${DELPHES_CARD} ${OUTPUT_CONFIG} pythia_resonance_decay_filter_pp_hhbbyy_output.root ${PROJECT_SOURCE_DIR}/examples/data/tester_pwp8_pp_hh_5f_hhbbyy.cmd --no-delphes)
endif()

ADD_COMPARISON_TEST(DelphesRootReader_ee_91gev DelphesROOT_EDM4HEP ${DELPHES_CARD} ${OUTPUT_CONFIG} delphes_root_converter_input_reader_test.root ${PROJECT_SOURCE_DIR}/tests/data/gev91ee_zboson_100events.root )
else()
message(WARNING "Cannot find IDEA delphes card from the delphes installation. Cannot use it for testing")
endif()
Binary file added tests/data/gev91ee_zboson_100events.root
Binary file not shown.
2 changes: 1 addition & 1 deletion tests/testDriver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ DELPHES_CARD_IN=${2}
OUTPUT_CONFIG=${3}
OUTPUT_FILE=${4}

DELPHES_CARD=$(pwd)/test_$(basename ${DELPHES_CARD_IN})
DELPHES_CARD=$(pwd)/$(mktemp -u test_XXXX_$(basename ${DELPHES_CARD_IN}))

# Keep track on whether this has been enabled from the calling site
xtrace_on=$(shopt -qo xtrace && echo "yes")
Expand Down

0 comments on commit 02a602e

Please sign in to comment.