Skip to content

Commit

Permalink
Add test for api.Station.event_time
Browse files Browse the repository at this point in the history
  • Loading branch information
153957 committed Apr 30, 2015
1 parent 074e4dd commit e1f1fc0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions sapphire/tests/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,12 @@ def test_has_weather(self):
def test_event_trace(self):
self.assertEqual(self.station.event_trace(1378771205, 571920029)[3][9], 268)

def test_event_time(self):
names = ('hour', 'counts')
data = self.station.event_time(2013, 1, 1)
self.assertEqual(data.dtype.names, names)
self.assertTrue((data['hour'] == range(24)).all())

def test_pulse_height(self):
names = ('pulseheight', 'ph1', 'ph2', 'ph3', 'ph4')
data = self.station.pulse_height(2013, 1, 1)
Expand Down

0 comments on commit e1f1fc0

Please sign in to comment.