Class MockMailer

  • All Implemented Interfaces:
    Mailer

    public class MockMailer
    extends Object
    implements Mailer
    • Constructor Detail

      • MockMailer

        public MockMailer()
    • Method Detail

      • send

        public void send​(Mail mail)
        Description copied from interface: Mailer
        Sends the given mail as the configured user@domain.
        Specified by:
        send in interface Mailer
      • user

        public String user()
        Description copied from interface: Mailer
        Returns the user this is configured to use.
        Specified by:
        user in interface Mailer
      • domain

        public String domain()
        Description copied from interface: Mailer
        Returns the domain this is configured to use.
        Specified by:
        domain in interface Mailer
      • inbox

        public List<Mail> inbox​(String recipient)
        Returns the list of mails sent to the given recipient. Modifications affect the set of mails stored in this.