ATLAS Offline Software
Loading...
Searching...
No Matches
MdtTwinTester.py
Go to the documentation of this file.
1# Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
2
3def MdtTwinCablingTestCfg(flags, name="MdtTwinMappingTestAlg", **kwargs):
4 from AthenaConfiguration.ComponentFactory import CompFactory
5 from AthenaConfiguration.ComponentAccumulator import ComponentAccumulator
6 result = ComponentAccumulator()
7 the_alg = CompFactory.Muon.MdtTwinTubeTestAlg(name=name, **kwargs)
8 result.addEventAlgo(the_alg, primary = True)
9 return result
10
11
12if __name__ == "__main__":
13 from MuonGeoModelTestR4.testGeoModel import setupGeoR4TestCfg, SetupArgParser, executeTest
14 parser = SetupArgParser()
15 parser.add_argument("--cablingJSON", help="Location of the twin tube cabling file to test", type=str, default="")
16 parser.set_defaults(nEvents = 1)
17 parser.set_defaults(noMM=True)
18 parser.set_defaults(noSTGC=True)
19 parser.set_defaults(noRpc=True)
20 parser.set_defaults(noTgc=True)
21
22 args = parser.parse_args()
23 flags, cfg = setupGeoR4TestCfg(args)
24 from MuonConfig.MuonCablingConfig import MdtTwinTubeMapCondAlgCfg
25 cfg.merge(MdtTwinTubeMapCondAlgCfg(flags, JSONFile = args.cablingJSON))
26 cfg.merge(MdtTwinCablingTestCfg(flags))
27 executeTest(cfg)
MdtTwinCablingTestCfg(flags, name="MdtTwinMappingTestAlg", **kwargs)