moto/tests/test_medialive/test_server.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

30 lines
694 B
Python
Raw Normal View History

import json
import moto.server as server
2024-01-07 12:03:33 +00:00
from moto import mock_aws
"""
Test the different server responses
"""
2024-01-07 12:03:33 +00:00
@mock_aws
def test_medialive_list_channels():
backend = server.create_backend_app("medialive")
test_client = backend.test_client()
res = test_client.get("/prod/channels")
result = res.data.decode("utf-8")
assert json.loads(result) == {"channels": [], "nextToken": None}
2024-01-07 12:03:33 +00:00
@mock_aws
def test_medialive_list_inputs():
backend = server.create_backend_app("medialive")
test_client = backend.test_client()
res = test_client.get("/prod/inputs")
result = res.data.decode("utf-8")
assert json.loads(result) == {"inputs": [], "nextToken": None}