* write boilerplate code * generate boilerplate code with scaffold script * create mediapackage channel * remove duplicate mediapackage reference * remove Channel key from mediapackage response * describe_channel endpoint added * create_origin_endpoint-added * keys changed to camel case to fix issue * minor changes to clean up * minor clean up again * implement & test delete_channel * delete origin endpoint created; WIP-tests failing * fix delete_origin_endpoint issue * refactor function call * delete origin endpoint completed; test_server tests added * implement and test describe_origin_endpoint * update origin endpoint added * remove print statements * implement test_list_origin_endpoint_succeeds * create test name changed * create test name changed * changes after flake8 and black run * url assertion added to decribe origin endpoint test * region dependent url enabled * initial commit; WIP * create container added, still WIP * create_container working * test_create_channel_succeeds * test_describe_container_succeeds * get_lifecycle_policy added; error tests added * changes to pass linting * added exception for container but no policy * linting * put_container_policy added * put_metric_policy added * list_containers added * resolved linting * test_describe_container_raises_error_if_container_does_not_exist * added __init__ file * __init__ added to mediapackage as well * Mediastore (#20) * initial commit; WIP * create container added, still WIP * create_container working * test_create_channel_succeeds * test_describe_container_succeeds * get_lifecycle_policy added; error tests added * changes to pass linting * added exception for container but no policy * linting * put_container_policy added * put_metric_policy added * list_containers added * resolved linting * test_describe_container_raises_error_if_container_does_not_exist * added __init__ file * __init__ added to mediapackage as well Co-authored-by: FranckNdame <franck.mpouli@yahoo.com> * test_server fixed; resolved rebasing mix ups on tests * [FIX] Ensures MediaConnect create_flow sets a valid sourceArn * code clean up Co-authored-by: Anya <anya.champaneria@capablue.com> Co-authored-by: AnyaChamp <71766808+AnyaChamp@users.noreply.github.com>
23 lines
716 B
Python
23 lines
716 B
Python
from __future__ import unicode_literals
|
|
from moto.core.exceptions import JsonRESTError
|
|
|
|
|
|
class MediaStoreClientError(JsonRESTError):
|
|
code = 400
|
|
|
|
|
|
class ResourceNotFoundException(MediaStoreClientError):
|
|
def __init__(self, msg=None):
|
|
self.code = 400
|
|
super(ResourceNotFoundException, self).__init__(
|
|
"ResourceNotFoundException", msg or "The specified container does not exist"
|
|
)
|
|
|
|
|
|
class PolicyNotFoundException(MediaStoreClientError):
|
|
def __init__(self, msg=None):
|
|
self.code = 400
|
|
super(PolicyNotFoundException, self).__init__(
|
|
"PolicyNotFoundException",
|
|
msg or "The policy does not exist within the specfied container",
|
|
)
|