hass-core/homeassistant/components/speedtestdotnet/const.py
Ville Skyttä 3e23a3a860
Add and use bunch of data size and rate related constants (#31781)
Also fix a few units to match the corresponding data.
2020-02-13 08:52:57 -08:00

12 lines
333 B
Python

"""Consts used by Speedtest.net."""
from homeassistant.const import DATA_RATE_MEGABITS_PER_SECOND
DOMAIN = "speedtestdotnet"
DATA_UPDATED = f"{DOMAIN}_data_updated"
SENSOR_TYPES = {
"ping": ["Ping", "ms"],
"download": ["Download", DATA_RATE_MEGABITS_PER_SECOND],
"upload": ["Upload", DATA_RATE_MEGABITS_PER_SECOND],
}