Esempio n. 1
0
 def test_get_point_id_success(self):
     service = HubCommunicationService()
     self.assertEqual("/RoomX/PointDFS",
                      service.get_point_id("/Ard/In/RoomX/PointDFS"))
     self.assertEqual("/Room1/Point1",
                      service.get_point_id("/Pi/In/Room1/Point1"))
     self.assertEqual("/Room1/Point1/SubPoint",
                      service.get_point_id("/Pi/In/Room1/Point1/SubPoint"))
     self.assertEqual(None, service.get_point_id("/Pi/Out/Room1/Point1"))
     self.assertEqual(None, service.get_point_id(""))
Esempio n. 2
0
 def test_get_point_id_none(self):
     service = HubCommunicationService()
     self.assertEqual(None, service.get_point_id(None))