Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:28:35

0001 
0002 # This configuration is designed to be run as the last
0003 # in a series of cmsRun processes.
0004 
0005 # Tests the maxLuminosityBlocks parameter
0006 
0007 # checks to see that the process level fakeRaw overrides the file based one
0008 
0009 import FWCore.ParameterSet.Config as cms
0010 
0011 process = cms.Process("PROD2TEST")
0012 
0013 process.maxLuminosityBlocks = cms.untracked.PSet(
0014   input = cms.untracked.int32(3)
0015 )
0016 
0017 process.load("FWCore.MessageService.MessageLogger_cfi")
0018 process.MessageLogger.cerr.FwkReport.reportEvery = 1000
0019 
0020 import FWCore.Framework.test.cmsExceptionsFatalOption_cff
0021 process.options = cms.untracked.PSet(
0022 #  wantSummary = cms.untracked.bool(True),
0023   Rethrow = FWCore.Framework.test.cmsExceptionsFatalOption_cff.Rethrow
0024 )
0025 
0026 process.source = cms.Source("PoolSource",
0027   fileNames = cms.untracked.vstring('file:testSeriesOfProcessesTEST.root'),
0028 )
0029 
0030 # Override the fakeRaw found in the test file
0031 process.fakeRaw = cms.EDProducer(
0032   "IntProducer",
0033   ivalue = cms.int32(20)
0034 )
0035 
0036 
0037 # This module tests to see if the products put in at the first step
0038 # (the fake HLT step) survived through to the last file.  At the PROD
0039 # stage the products were split into two files so this test secondary
0040 # file input.
0041 process.a = cms.EDAnalyzer("TestFindProduct",
0042   inputTags = cms.untracked.VInputTag( cms.InputTag("fakeRaw"),
0043                                        cms.InputTag("fakeHLTDebug") ),
0044 
0045   # Test the maxLuminosityBlock parameter
0046   # 3 luminosity blocks contain 15 events
0047   # Each event contains one product with a value of 20 and
0048   # one product with a value of 1000
0049   # If the maxLuminosityBlock parameter is working correctly the
0050   # following should be the sum of all the values.
0051   # The product values are hard coded into the fake
0052   # HLT configuration (the first one in this series).
0053   expectedSum = cms.untracked.int32(15300)
0054 )
0055 
0056 process.test1 = cms.Path(process.fakeRaw*process.a)
0057 
0058 process.out = cms.OutputModule("PoolOutputModule",
0059   fileName = cms.untracked.string('testSeriesOfProcessesPROD2TEST.root'),
0060   outputCommands = cms.untracked.vstring(
0061     "keep *"
0062   )
0063 )
0064 process.o = cms.EndPath(process.out)