diff --git a/homeassistant/components/tasmota/manifest.json b/homeassistant/components/tasmota/manifest.json index c270be6e633..6140de6025a 100644 --- a/homeassistant/components/tasmota/manifest.json +++ b/homeassistant/components/tasmota/manifest.json @@ -3,7 +3,7 @@ "name": "Tasmota (beta)", "config_flow": true, "documentation": "https://www.home-assistant.io/integrations/tasmota", - "requirements": ["hatasmota==0.0.31"], + "requirements": ["hatasmota==0.0.32"], "dependencies": ["mqtt"], "mqtt": ["tasmota/discovery/#"], "codeowners": ["@emontnemery"] diff --git a/requirements_all.txt b/requirements_all.txt index d2d9acef763..d4a35de3e97 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -741,7 +741,7 @@ hass-nabucasa==0.38.0 hass_splunk==0.1.1 # homeassistant.components.tasmota -hatasmota==0.0.31 +hatasmota==0.0.32 # homeassistant.components.jewish_calendar hdate==0.9.12 diff --git a/requirements_test_all.txt b/requirements_test_all.txt index 24b01699aa0..de236d4f0fd 100644 --- a/requirements_test_all.txt +++ b/requirements_test_all.txt @@ -379,7 +379,7 @@ hangups==0.4.11 hass-nabucasa==0.38.0 # homeassistant.components.tasmota -hatasmota==0.0.31 +hatasmota==0.0.32 # homeassistant.components.jewish_calendar hdate==0.9.12 diff --git a/tests/components/tasmota/test_discovery.py b/tests/components/tasmota/test_discovery.py index b6a51a38daf..40fecb6b695 100644 --- a/tests/components/tasmota/test_discovery.py +++ b/tests/components/tasmota/test_discovery.py @@ -22,6 +22,25 @@ async def test_subscribing_config_topic(hass, mqtt_mock, setup_tasmota): assert call_args[2] == 0 +async def test_future_discovery_message(hass, mqtt_mock, caplog): + """Test we handle backwards compatible discovery messages.""" + config = copy.deepcopy(DEFAULT_CONFIG) + config["future_option"] = "BEST_SINCE_SLICED_BREAD" + config["so"]["another_future_option"] = "EVEN_BETTER" + + with patch( + "homeassistant.components.tasmota.discovery.tasmota_get_device_config", + return_value={}, + ) as mock_tasmota_get_device_config: + await setup_tasmota_helper(hass) + + async_fire_mqtt_message( + hass, f"{DEFAULT_PREFIX}/00000049A3BC/config", json.dumps(config) + ) + await hass.async_block_till_done() + assert mock_tasmota_get_device_config.called + + async def test_valid_discovery_message(hass, mqtt_mock, caplog): """Test discovery callback called.""" config = copy.deepcopy(DEFAULT_CONFIG)