Esempio n. 1
0
 def test_should_find_correct_sensorname(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertEquals(goose._get_sensorname(), 'cleese')
Esempio n. 2
0
 def test_should_find_triptype_high(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertEquals(goose.triptype, 'High')
Esempio n. 3
0
 def test_event_event_post(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertTrue(goose.post_event())
Esempio n. 4
0
 def test_should_find_correct_goosename(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertEquals(goose.goosename, self.goosename)
Esempio n. 5
0
 def test_should_find_climate_values(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertEquals(goose.climatevalue, self.temperature)
Esempio n. 6
0
 def test_init_should_parse_trap_without_error(self):
     self.assertTrue(wg.WeatherGoose1(self.trap, None, None, None))
Esempio n. 7
0
 def test_should_find_correct_alert_type(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     self.assertEquals(goose._get_alert_type(), 'cmClimateTempCTRAP')
Esempio n. 8
0
 def test_should_find_correct_sensorname(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     assert goose._get_sensorname() == 'cleese'
Esempio n. 9
0
 def test_should_find_triptype_high(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     assert goose.triptype == 'High'
Esempio n. 10
0
 def test_should_find_climate_values(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     assert goose.climatevalue == self.temperature
Esempio n. 11
0
 def test_should_find_correct_goosename(self):
     goose = wg.WeatherGoose1(self.trap, None, None, None)
     assert goose.goosename == self.goosename
Esempio n. 12
0
 def test_init_should_raise_on_invalid_oid(self):
     trap = Mock(snmpTrapOID='5')
     with pytest.raises(Exception):
         wg.WeatherGoose1(trap, None, None, None)