diff --git a/tests/data/minimalistic.dec b/tests/data/minimalistic.dec index c83e133f..7b2ab869 100644 --- a/tests/data/minimalistic.dec +++ b/tests/data/minimalistic.dec @@ -1,7 +1,7 @@ # Example decfile for testing purposes: # Line with "End" is strictly speaking not necessary -# Such "empty" files are relevant in LHCb for example when special decays are all defined in PYthon code +# Such "empty" files are relevant in LHCb for example when special decays are all defined in Python code # inserted in commented-out lines End # diff --git a/tests/dec/test_dec.py b/tests/dec/test_dec.py index dd4e31d3..f6c4b8ac 100644 --- a/tests/dec/test_dec.py +++ b/tests/dec/test_dec.py @@ -101,6 +101,14 @@ def test_non_parsed_decfile(): p.list_decay_mother_names() +def test_decfile_defining_stable_particle(): + p = DecFileParser(DIR / "../data/test_stable-particle.dec") + p.parse() + + assert p.number_of_decays == 1 # The decay of K_S0, even if no decay modes are defined + assert p.list_decay_modes("K_S0") == [] + + def test_non_existent_decay(): p = DecFileParser(DIR / "../data/test_example_Dst.dec") p.parse()