Class AssertableMailpitResponse

java.lang.Object
net.bugreaper.modules.api.assertable.AssertableResponseAbstract
net.bugreaper.modules.email.assertable.AssertableMailpitResponse
All Implemented Interfaces:
ResponseMailpitInterface

public class AssertableMailpitResponse extends net.bugreaper.modules.api.assertable.AssertableResponseAbstract implements ResponseMailpitInterface
Provides a fluent API for asserting and extracting data from Email messages (API responses).

This class is designed to be used in a chainable manner, allowing multiple assertions to be performed in a single readable statement.

Usage Example:


 mailpit.getLatestEmailInMailbox("my_email@gmail.com")
         .seeEmailContainsFrom("sender@gmail.com")
         .seeEmailAttachmentsCountExactly(2);
 

Design Notes:

  • All assertion methods return this to support fluent chaining.
  • Assertion logic is delegated to internal helper methods to keep steps readable.
  • Failures should throw assertion errors to immediately fail the test.