Example #1
0
 def test_check_data_key_error(self):
     """ Data is put into check_data to test if there is a type given """
     data = {"unitid": "car", "min": 0}
     self.assertEqual(check_data(data), "No type given")
Example #2
0
 def test_check_data_else(self):
     """ Data is put into check_data to test if a valid type is given """
     data = {"type": "566ebaec8bd7c7b93daefa1b", "index": 0}
     self.assertEqual(check_data(data), "The type is invalid")
Example #3
0
 def test_check_data_events(self):
     """ Events data is put into check_data to see if events parsed
         is the result
     """
     data = {"type": "events", "unitid": 92847872745648674865798646874961536}
     self.assertEqual(check_data(data), "Events parsed")
Example #4
0
 def test_check_data_connections(self):
     """ Connections data is put into check_data to see if positions parsed
         is the result
     """
     data = {"type": "connections", "unitid": 92847872745648674865798646874961536}
     self.assertEqual(check_data(data), "Connections parsed")
Example #5
0
 def test_check_data_monitoring(self):
     """ Monitoring data is put into check_data to see if monitoring parsed
         is the result
     """
     data = {"type": "monitoring", "unitid": 92847872745648674865798646874961536}
     self.assertEqual(check_data(data), "Monitoring parsed")
Example #6
0
 def test_check_data_car(self):
     """ Car data is put into check_data to see if car parsed is the result """
     data = {"type": "car", "unitid": 92847872745648674865798646874961536}
     self.assertEqual(check_data(data), "Car parsed")