CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
Harness Class Reference

Public Member Functions

edmtest::ThingCollection getBeginLumiValue (unsigned int iLumi)
 
edmtest::IntProduct getBeginLumiValue (unsigned int iLumi)
 
ExternalGeneratorLumiInfo getBeginLumiValue (unsigned int iLumi)
 
edmtest::ThingCollection getBeginRunValue (unsigned int iRun)
 
edmtest::ThingCollection getEndLumiValue ()
 
GenLumiInfoProduct getEndLumiValue ()
 
edmtest::ThingCollection getEndRunValue ()
 
GenRunInfoProduct getEndRunValue ()
 
edmtest::ThingCollection getEventValue ()
 
edmtest::IntProduct getEventValue ()
 
ExternalGeneratorEventInfo getEventValue ()
 
 Harness (std::string const &iConfig)
 
 Harness (std::string const &iConfig, edm::ServiceToken iToken)
 
 Harness (std::string const &iConfig, edm::ServiceToken iToken)
 

Private Attributes

edm::test::TestProcessor tester_
 

Detailed Description

Definition at line 28 of file interprocess.cc.

Constructor & Destructor Documentation

◆ Harness() [1/3]

Harness::Harness ( std::string const &  iConfig)
inline

Definition at line 30 of file interprocess.cc.

◆ Harness() [2/3]

Harness::Harness ( std::string const &  iConfig,
edm::ServiceToken  iToken 
)
inline

Definition at line 36 of file interprocess_random.cc.

37  : tester_(edm::test::TestProcessor::Config{iConfig}, iToken) {}

◆ Harness() [3/3]

Harness::Harness ( std::string const &  iConfig,
edm::ServiceToken  iToken 
)
inline

Definition at line 42 of file externalGenerator.cc.

43  : tester_(edm::test::TestProcessor::Config{iConfig}, iToken) {}

Member Function Documentation

◆ getBeginLumiValue() [1/3]

edmtest::ThingCollection Harness::getBeginLumiValue ( unsigned int  iLumi)
inline

Definition at line 37 of file interprocess.cc.

37  {
39  return *lumi.get<edmtest::ThingCollection>("beginLumi");
40  }

Referenced by main().

◆ getBeginLumiValue() [2/3]

edmtest::IntProduct Harness::getBeginLumiValue ( unsigned int  iLumi)
inline

Definition at line 39 of file interprocess_random.cc.

39  {
41  return *lumi.get<edmtest::IntProduct>("lumi");
42  }

◆ getBeginLumiValue() [3/3]

ExternalGeneratorLumiInfo Harness::getBeginLumiValue ( unsigned int  iLumi)
inline

Definition at line 45 of file externalGenerator.cc.

45  {
47  ExternalGeneratorLumiInfo returnValue;
48  returnValue.header_ = *lumi.get<GenLumiInfoHeader>();
49  return returnValue;
50  }

References ExternalGeneratorLumiInfo::header_.

◆ getBeginRunValue()

edmtest::ThingCollection Harness::getBeginRunValue ( unsigned int  iRun)
inline

Definition at line 32 of file interprocess.cc.

32  {
33  auto run = tester_.testBeginRun(iRun);
34  return *run.get<edmtest::ThingCollection>("beginRun");
35  }

References writedatasetfile::run.

Referenced by main().

◆ getEndLumiValue() [1/2]

edmtest::ThingCollection Harness::getEndLumiValue ( )
inline

Definition at line 47 of file interprocess.cc.

47  {
49  return *lumi.get<edmtest::ThingCollection>("endLumi");
50  }

Referenced by main().

◆ getEndLumiValue() [2/2]

GenLumiInfoProduct Harness::getEndLumiValue ( )
inline

Definition at line 61 of file externalGenerator.cc.

61  {
63  return *lumi.get<GenLumiInfoProduct>();
64  }

◆ getEndRunValue() [1/2]

edmtest::ThingCollection Harness::getEndRunValue ( )
inline

Definition at line 52 of file interprocess.cc.

52  {
53  auto run = tester_.testEndRun();
54  return *run.get<edmtest::ThingCollection>("endRun");
55  }

References writedatasetfile::run.

Referenced by main().

◆ getEndRunValue() [2/2]

GenRunInfoProduct Harness::getEndRunValue ( )
inline

Definition at line 66 of file externalGenerator.cc.

66  {
67  auto run = tester_.testEndRun();
68  return *run.get<GenRunInfoProduct>();
69  }

References writedatasetfile::run.

◆ getEventValue() [1/3]

edmtest::ThingCollection Harness::getEventValue ( )
inline

Definition at line 42 of file interprocess.cc.

42  {
43  auto event = tester_.test();
44  return *event.get<edmtest::ThingCollection>();
45  }

Referenced by main().

◆ getEventValue() [2/3]

edmtest::IntProduct Harness::getEventValue ( )
inline

Definition at line 44 of file interprocess_random.cc.

44  {
45  auto event = tester_.test();
46  return *event.get<edmtest::IntProduct>();
47  }

◆ getEventValue() [3/3]

ExternalGeneratorEventInfo Harness::getEventValue ( )
inline

Definition at line 52 of file externalGenerator.cc.

52  {
53  ExternalGeneratorEventInfo returnValue;
54  auto event = tester_.test();
55  returnValue.hepmc_ = *event.get<edm::HepMCProduct>("unsmeared");
56  returnValue.eventInfo_ = *event.get<GenEventInfoProduct>();
57  returnValue.keepEvent_ = event.modulePassed();
58  return returnValue;
59  }

References ExternalGeneratorEventInfo::eventInfo_, ExternalGeneratorEventInfo::hepmc_, and ExternalGeneratorEventInfo::keepEvent_.

Member Data Documentation

◆ tester_

edm::test::TestProcessor Harness::tester_
private

Definition at line 58 of file interprocess.cc.

GenEventInfoProduct
Definition: GenEventInfoProduct.h:17
edm::test::TestProcessor::test
edm::test::Event test(T &&... iArgs)
Definition: TestProcessor.h:170
Harness::tester_
edm::test::TestProcessor tester_
Definition: interprocess.cc:58
edm::test::TestProcessor::testBeginLuminosityBlock
edm::test::LuminosityBlock testBeginLuminosityBlock(edm::LuminosityBlockNumber_t iNum, T &&... iArgs)
Definition: TestProcessor.h:175
edm::test::TestProcessorConfig
Definition: TestProcessor.h:89
edm::test::TestProcessor::testEndLuminosityBlock
edm::test::LuminosityBlock testEndLuminosityBlock(T &&... iArgs)
Definition: TestProcessor.h:179
ExternalGeneratorEventInfo::hepmc_
edm::HepMCProduct hepmc_
Definition: ExternalGeneratorEventInfo.h:15
ExternalGeneratorLumiInfo::header_
GenLumiInfoHeader header_
Definition: ExternalGeneratorLumiInfo.h:14
edm::test::TestProcessor::testEndRun
edm::test::Run testEndRun(T &&... iArgs)
Definition: TestProcessor.h:188
GenRunInfoProduct
Definition: GenRunInfoProduct.h:8
ExternalGeneratorEventInfo::eventInfo_
GenEventInfoProduct eventInfo_
Definition: ExternalGeneratorEventInfo.h:16
GenLumiInfoProduct
Definition: GenLumiInfoProduct.h:11
ExternalGeneratorLumiInfo
Definition: ExternalGeneratorLumiInfo.h:13
ExternalGeneratorEventInfo::keepEvent_
bool keepEvent_
Definition: ExternalGeneratorEventInfo.h:18
writedatasetfile.run
run
Definition: writedatasetfile.py:27
edm::test::TestProcessor::testBeginRun
edm::test::Run testBeginRun(edm::RunNumber_t iNum, T &&... iArgs)
Definition: TestProcessor.h:184
edm::HepMCProduct
Definition: HepMCProduct.h:18
lumi
Definition: LumiSectionData.h:20
edm::test::Event::get
TestHandle< T > get() const
Definition: Event.h:42
GenLumiInfoHeader
Definition: GenLumiInfoHeader.h:12
ExternalGeneratorEventInfo
Definition: ExternalGeneratorEventInfo.h:14