def test_humidity_assert_min_exceeded(self): """Test parsing of DPTHumidity with wrong value.""" with pytest.raises(ConversionError): DPTHumidity.to_knx(-1)
def test_humidity_settings(self): """Test attributes of DPTHumidity.""" self.assertEqual(DPTHumidity().value_min, 0) self.assertEqual(DPTHumidity().value_max, 670760) self.assertEqual(DPTHumidity().unit, "%") self.assertEqual(DPTHumidity().resolution, 1)