mirror of
https://github.com/home-assistant/supervisor.git
synced 2025-07-10 18:56:30 +00:00
Tweak check API path (#2714)
This commit is contained in:
parent
73849b7468
commit
e30171746b
@ -228,9 +228,7 @@ class RestAPI(CoreSysAttributes):
|
|||||||
self.webapp.add_routes(
|
self.webapp.add_routes(
|
||||||
[
|
[
|
||||||
web.get("/resolution/info", api_resolution.info),
|
web.get("/resolution/info", api_resolution.info),
|
||||||
web.post(
|
web.post("/resolution/check/{check}", api_resolution.options_check),
|
||||||
"/resolution/check/{check}/options", api_resolution.options_check
|
|
||||||
),
|
|
||||||
web.post(
|
web.post(
|
||||||
"/resolution/suggestion/{suggestion}",
|
"/resolution/suggestion/{suggestion}",
|
||||||
api_resolution.apply_suggestion,
|
api_resolution.apply_suggestion,
|
||||||
|
@ -109,11 +109,11 @@ async def test_api_resolution_check_options(coresys: CoreSys, api_client):
|
|||||||
|
|
||||||
assert free_space.enabled
|
assert free_space.enabled
|
||||||
await api_client.post(
|
await api_client.post(
|
||||||
f"/resolution/check/{free_space.slug}/options", json={"enabled": False}
|
f"/resolution/check/{free_space.slug}", json={"enabled": False}
|
||||||
)
|
)
|
||||||
assert not free_space.enabled
|
assert not free_space.enabled
|
||||||
|
|
||||||
await api_client.post(
|
await api_client.post(
|
||||||
f"/resolution/check/{free_space.slug}/options", json={"enabled": True}
|
f"/resolution/check/{free_space.slug}", json={"enabled": True}
|
||||||
)
|
)
|
||||||
assert free_space.enabled
|
assert free_space.enabled
|
||||||
|
Loading…
x
Reference in New Issue
Block a user