def test_device_id_should_be_number(self): with open('{}/api_responses/v1_hub.json'.format(os.path.dirname(__file__))) as hub_file: response_dict = json.load(hub_file) hub = response_dict.get('data')[0] wink_hub = WinkHub(hub, self.api_interface) device_id = wink_hub.device_id() self.assertRegex(device_id, "^[0-9]{4,6}")
def test_device_id_should_be_number(self): with open('{}/api_responses/v1_hub.json'.format( os.path.dirname(__file__))) as hub_file: response_dict = json.load(hub_file) hub = response_dict.get('data')[0] wink_hub = WinkHub(hub, self.api_interface) device_id = wink_hub.device_id() self.assertRegex(device_id, "^[0-9]{4,6}")