22 lines
690 B
Python
22 lines
690 B
Python
from __future__ import annotations
|
|
|
|
from pathlib import Path
|
|
|
|
import yaml # type: ignore[import-untyped]
|
|
|
|
|
|
def test_addon_config_declares_future_addon() -> None:
|
|
config = yaml.safe_load(Path("addon/config.yaml").read_text(encoding="utf-8"))
|
|
|
|
assert config["slug"] == "sillyhome_future"
|
|
assert config["version"] == "2.0.0-alpha.7"
|
|
assert config["ingress"] is True
|
|
assert config["ingress_port"] == 8099
|
|
assert config["homeassistant_api"] is True
|
|
|
|
|
|
def test_repository_points_to_gitea_repo() -> None:
|
|
repository = yaml.safe_load(Path("repository.yaml").read_text(encoding="utf-8"))
|
|
|
|
assert repository["url"] == "http://192.168.6.31:3000/Otto/sillyhome-future"
|