Skip to content

Fix logic for special generator handling

Spyros Argyropoulos requested to merge fixLP into master

Description of bug

Currently some checks (TestHepMC and metadata) are excluded for special generators only if the generator name is an identical match to the names in the specialGenerators list. This means e.g. that a ParticleGun sample will be excluded from these tests while a ParticleGun+EvtGen sample wouldn't.

Changes introduced

Only match substring from generator name to the list of special generators.

Tests

Before fix

MISSING Metadata:
ParticleGun+EvtGen(v.1.7.0)
 ERROR: generatorTune is missing!
INFO: genFilterNames is missing
 ERROR: cross-section (nb) is missing!
INFO: generator is missing
INFO: weights is missing
INFO: PDF is missing

-------------------------
Generator specific tests: ParticleGun+EvtGen(v.1.7.0)
-------------------------

---------------------
Failed tests:
 ERROR: TestHepMC Events passed is missing!
 ERROR: TestHepMC Efficiency is missing!

---------------------
 Summary:
---------------------
Errors : 4 , Warnings : 0  -> Errors encountered! Not ready for production!

After fix

INFO: generatorTune is missing
INFO: genFilterNames is missing
INFO: cross-section (nb) is missing
INFO: generator is missing
INFO: weights is missing
INFO: PDF is missing

-------------------------
Generator specific tests: ParticleGun+EvtGen(v.1.7.0)
-------------------------

---------------------
Failed tests:
 WARNING: TestHepMC Events passed is missing
 WARNING: TestHepMC Efficiency is missing


---------------------
 Summary:
---------------------
Errors : 0 , Warnings : 2  -> Some warnings encountered, check that these are ok before submitting production!

Issues resolved

Closes #

Merge request reports