add support for Fn::GetAtt in event's cloudformation

This commit is contained in:
Guilherme Martins Crocetti 2020-04-01 22:00:20 -03:00
commit c15ca133b8
2 changed files with 45 additions and 0 deletions

View file

@ -59,6 +59,14 @@ class Rule(BaseModel):
if index is not None:
self.targets.pop(index)
def get_cfn_attribute(self, attribute_name):
from moto.cloudformation.exceptions import UnformattedGetAttTemplateException
if attribute_name == "Arn":
return self.arn
raise UnformattedGetAttTemplateException()
@classmethod
def create_from_cloudformation_json(
cls, resource_name, cloudformation_json, region_name