Coverage for src/kwai/core/mail/mailer.py: 100%
4 statements
« prev ^ index » next coverage.py v7.6.10, created at 2024-01-01 00:00 +0000
« prev ^ index » next coverage.py v7.6.10, created at 2024-01-01 00:00 +0000
1"""Module that defines an interface for a mail service."""
3from abc import ABC, abstractmethod
5from .message import Message
8class MailerException(Exception):
9 """Exception raised from a Mailer."""
12class Mailer(ABC):
13 """Interface for a mail service."""
15 @abstractmethod
16 def send(self, message: Message):
17 """Send the message."""
18 raise NotImplementedError