Beispiel #1
0
 def testTemperatureStatus(self):
     ts = temperature.TemperatureStatus()
     ts.AddSensor(name='Test1', sensor=MockSensor())
     ts.AddSensor(name='Test2', sensor=MockSensor())
     ts.ValidateExports()
     self.assertEqual(ts.TemperatureSensorNumberOfEntries, 2)
     self.assertEqual(ts.TemperatureSensorList[1].Name, 'Test1')
     self.assertEqual(ts.TemperatureSensorList[2].Name, 'Test2')
Beispiel #2
0
 def __init__(self, device_id, ioloop=None):
     super(DeviceInfo181Linux26, self).__init__()
     assert isinstance(device_id, DeviceIdMeta)
     self.ioloop = ioloop or tornado.ioloop.IOLoop.instance()
     self._device_id = device_id
     self.Unexport(['FirstUseDate', 'ProvisioningCode'])
     self.Unexport(objects=['NetworkProperties', 'ProxierInfo'])
     self.LocationList = {}
     self.ProcessStatus = ProcessStatusLinux26(ioloop=ioloop)
     self.TemperatureStatus = temperature.TemperatureStatus()
     self.VendorLogFileList = {}
     self.VendorConfigFileList = {}
     self.SupportedDataModelList = {}
     self.ProcessorList = {}
     self.X_CATAWAMPUS_ORG_LedStatusList = {}
     self._next_led_number = 1