dav_base.emails: make coverage happy
Run tests / Execute tox to run the test suite (push) Successful in 3m33s

This commit is contained in:
2026-05-21 16:29:37 +02:00
parent 4d9da28e69
commit 6b9c490f92
3 changed files with 25 additions and 8 deletions
+3 -6
View File
@@ -48,7 +48,7 @@ class AbstractMail: # pylint: disable=too-few-public-methods
def _get_reply_to(self):
return None
def send(self, fail_silently=False):
def send(self):
subject = self._get_subject()
body = self._get_body()
sender = self._get_sender()
@@ -56,8 +56,5 @@ class AbstractMail: # pylint: disable=too-few-public-methods
reply_to = self._get_reply_to()
email = EmailMessage(subject=subject, body=body, from_email=sender, to=recipients, reply_to=reply_to)
if fail_silently:
logger.info('Fake sending %s to %s', self.__class__.__name__, recipients)
else:
logger.info('Send %s to %s', self.__class__.__name__, recipients)
email.send(fail_silently=fail_silently)
logger.info('Send %s to %s', self.__class__.__name__, recipients)
email.send()