ATLAS Offline Software
TrigTrackingPassFlags.py
Go to the documentation of this file.
1 # Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
2 import AthenaCommon.SystemOfUnits as Units
3 
4 
5 def createTrigTrackingPassFlags(mode="InDet"):
6 
7  from TrigInDetConfig.BuildSignatureFlags import signatureTrigTrackingFlags
8  return signatureTrigTrackingFlags(mode)
9 
10 
11 
12 import unittest
13 
14 class FlagsCopiedTest(unittest.TestCase):
15  def setUp(self):
16  from AthenaConfiguration.AllConfigFlags import initConfigFlags
17  flags = initConfigFlags()
18  flags.Trigger.doID
19  flags.Trigger.InDetTracking.muon
20  flags.Trigger.InDetTracking.electron.minPT = 2.0 * Units.GeV
21  flags.Trigger.ITkTracking.muon
22  self.newflags = flags.cloneAndReplace('Tracking.ActiveConfig', 'Trigger.InDetTracking.electron')
23  self.newflags4 = flags.cloneAndReplace('Tracking.ActiveConfig', 'Trigger.ITkTracking.muon')
24 
25  self.newflags.dump(".*InDet")
26 
27  def runTest(self):
28  self.assertEqual(self.newflags.Tracking.ActiveConfig.minPT, 2.0 * Units.GeV, msg="Flags are not copied")
29  self.assertEqual(type(self.newflags4.Tracking.ActiveConfig.minPT), list, msg="Eta dependant cuts don't exist")
30 
31 
32 if __name__ == "__main__":
33  unittest.main()
SystemOfUnits
python.TrigTrackingPassFlags.FlagsCopiedTest.newflags4
newflags4
Definition: TrigTrackingPassFlags.py:23
run_Egamma1_LArStrip_Fex.dump
dump
Definition: run_Egamma1_LArStrip_Fex.py:88
python.BuildSignatureFlags.signatureTrigTrackingFlags
AthConfigFlags signatureTrigTrackingFlags(str mode)
Definition: BuildSignatureFlags.py:157
python.TrigTrackingPassFlags.createTrigTrackingPassFlags
def createTrigTrackingPassFlags(mode="InDet")
Definition: TrigTrackingPassFlags.py:5
python.TrigTrackingPassFlags.FlagsCopiedTest.newflags
newflags
Definition: TrigTrackingPassFlags.py:22
python.TrigTrackingPassFlags.FlagsCopiedTest.setUp
def setUp(self)
Definition: TrigTrackingPassFlags.py:15
python.TrigTrackingPassFlags.FlagsCopiedTest
Definition: TrigTrackingPassFlags.py:14
python.AllConfigFlags.initConfigFlags
def initConfigFlags()
Definition: AllConfigFlags.py:19
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
python.TrigTrackingPassFlags.FlagsCopiedTest.runTest
def runTest(self)
Definition: TrigTrackingPassFlags.py:27