'Test get device speed.'

def test_dyson_get_speed(self):

    device = _get_device_on()
    component = dyson.DysonPureCoolLinkDevice(self.hass, device)
    self.assertEqual(component.speed, 1)
    device = _get_device_off()
    component = dyson.DysonPureCoolLinkDevice(self.hass, device)
    self.assertEqual(component.speed, 4)
    device = _get_device_with_no_state()
    component = dyson.DysonPureCoolLinkDevice(self.hass, device)
    self.assertIsNone(component.speed)
    device = _get_device_auto()
    component = dyson.DysonPureCoolLinkDevice(self.hass, device)
    self.assertEqual(component.speed, 'AUTO')
