String formatting improvements for tests (2) (#33666)

This commit is contained in:
Franck Nijhof authored and GitHub committed 2020-04-05 00:33:07 +02:00
1 parent 906385172a
commit d7e9959442
19 files changed
+65 -76

No files matched your search

@@ -426,6 +426,7 @@ async def test_if_fires_on_state_change_with_for(hass, calls):
await hass.async_block_till_done()
assert len(calls) == 1
await hass.async_block_till_done()
assert calls[0].data[
"some"
] == "turn_off device - {} - unknown - 11 - 0:00:05".format(sensor1.entity_id)
assert (
calls[0].data["some"]
== f"turn_off device - {sensor1.entity_id} - unknown - 11 - 0:00:05"
)