From f50c6c2fb060024e4e6e3ffd91a316a659480963 Mon Sep 17 00:00:00 2001 From: Robert C Jensen Date: Tue, 17 Jul 2018 20:12:05 -0400 Subject: [PATCH] feature: add parameters back to Message models --- moto/ses/models.py | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/moto/ses/models.py b/moto/ses/models.py index b1135a406..3dced60f2 100644 --- a/moto/ses/models.py +++ b/moto/ses/models.py @@ -13,14 +13,21 @@ RECIPIENT_LIMIT = 50 class Message(BaseModel): - def __init__(self, message_id): + def __init__(self, message_id, source, subject, body, destinations): self.id = message_id + self.source = source + self.subject = subject + self.body = body + self.destinations = destinations class RawMessage(BaseModel): - def __init__(self, message_id): + def __init__(self, message_id, source, destinations, raw_data): self.id = message_id + self.source = source + self.destinations = destinations + self.raw_data = raw_data class SESQuota(BaseModel): @@ -79,7 +86,7 @@ class SESBackend(BaseBackend): ) message_id = get_random_message_id() - message = Message(message_id) + message = Message(message_id, source, subject, body, destinations) self.sent_messages.append(message) self.sent_message_count += recipient_count return message @@ -116,7 +123,7 @@ class SESBackend(BaseBackend): self.sent_message_count += recipient_count message_id = get_random_message_id() - message = RawMessage(message_id) + message = RawMessage(message_id, source, destinations, raw_data) self.sent_messages.append(message) return message