Skip to content

Commit

Permalink
Fix tests for inclusion of telescope data
Browse files Browse the repository at this point in the history
  • Loading branch information
maxnoe committed Jun 2, 2020
1 parent ed094fd commit d90b6d8
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions tests/simtel/test_simtelfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,13 +129,20 @@ def test_iterate_complete_file_zst():
def test_iterate_mc_events():
expected = 200
with SimTelFile(prod4_path) as f:
for counter, event in enumerate(f.iter_mc_events(), start=1):
assert 'event_id' in event
assert 'mc_shower' in event
assert 'mc_event' in event

assert counter == expected

with SimTelFile('tests/resources/lst_with_photons.simtel.zst') as f:
for counter, event in enumerate(f.iter_mc_events(), start=1):
assert event.keys() == {
'event_id',
'mc_shower', 'mc_event',
'photoelectrons', 'photons', 'emitter',
'photons', 'photoelectrons', 'emitter'
}
assert counter == expected


def test_allowed_tels():
Expand Down

0 comments on commit d90b6d8

Please sign in to comment.