1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-23 20:39:01 +00:00

Upgrade black to 20.8b1 (#39287)

This commit is contained in:
Franck Nijhof
2020-08-27 13:56:20 +02:00
committed by GitHub
parent 0d7eec710c
commit 1c2ebdf307
574 changed files with 4389 additions and 1725 deletions

View File

@@ -589,28 +589,40 @@ async def test_light_brightness_pct_conversion(hass):
assert state.attributes["brightness"] == 100
await hass.services.async_call(
"light", "turn_on", {"entity_id": entity.entity_id, "brightness_pct": 1}, True,
"light",
"turn_on",
{"entity_id": entity.entity_id, "brightness_pct": 1},
True,
)
_, data = entity.last_call("turn_on")
assert data["brightness"] == 3, data
await hass.services.async_call(
"light", "turn_on", {"entity_id": entity.entity_id, "brightness_pct": 2}, True,
"light",
"turn_on",
{"entity_id": entity.entity_id, "brightness_pct": 2},
True,
)
_, data = entity.last_call("turn_on")
assert data["brightness"] == 5, data
await hass.services.async_call(
"light", "turn_on", {"entity_id": entity.entity_id, "brightness_pct": 50}, True,
"light",
"turn_on",
{"entity_id": entity.entity_id, "brightness_pct": 50},
True,
)
_, data = entity.last_call("turn_on")
assert data["brightness"] == 128, data
await hass.services.async_call(
"light", "turn_on", {"entity_id": entity.entity_id, "brightness_pct": 99}, True,
"light",
"turn_on",
{"entity_id": entity.entity_id, "brightness_pct": 99},
True,
)
_, data = entity.last_call("turn_on")