1
0
mirror of https://github.com/home-assistant/core.git synced 2025-12-25 05:26:47 +00:00

Use HTTP_NOT_FOUND constant (#33835)

This commit is contained in:
springstan
2020-04-09 00:57:47 +02:00
committed by GitHub
parent ac9429988b
commit 9a40d5b7ed
29 changed files with 98 additions and 78 deletions

View File

@@ -5,6 +5,7 @@ from urllib.parse import urlparse
import pytest
from homeassistant.components.stream import request_stream
from homeassistant.const import HTTP_NOT_FOUND
from homeassistant.setup import async_setup_component
import homeassistant.util.dt as dt_util
@@ -49,7 +50,7 @@ async def test_hls_stream(hass, hass_client):
# Ensure playlist not accessible after stream ends
fail_response = await http_client.get(parsed_url.path)
assert fail_response.status == 404
assert fail_response.status == HTTP_NOT_FOUND
@pytest.mark.skip("Flaky in CI")
@@ -86,7 +87,7 @@ async def test_stream_timeout(hass, hass_client):
# Ensure playlist not accessible
fail_response = await http_client.get(parsed_url.path)
assert fail_response.status == 404
assert fail_response.status == HTTP_NOT_FOUND
@pytest.mark.skip("Flaky in CI")