test(mail): stateful IMAP mock harness + fix a flaky webhook capture test #384

Merged
KofTwentyTwo merged 3 commits from story/imap-mock-harness into dev 2026-08-14 19:09:51 +00:00
3 changed files with 1268 additions and 0 deletions

No files matched your search

+5
View File
@@ -9,6 +9,11 @@ repository.workspace = true
[lints]
workspace = true
[features]
# Exposes `test_server`, a stateful loopback IMAP server, to dependent crates'
# test suites. Never enabled in a production build.
test-support = []
[dependencies]
nuncio-core = { path = "../nuncio-core" }
tokio.workspace = true
+6
View File
@@ -10,6 +10,12 @@ pub mod mock;
pub mod parser;
pub mod smtp;
// A real loopback IMAP server for offline tests. Behind a feature so it never
// enters a production build, but visible to this crate's own tests and to
// dependents that opt in (integration suites in `nunciod`).
#[cfg(any(test, feature = "test-support"))]
pub mod test_server;
pub use backend::{
MailBackend, MessageSender, OutboundMessage, RemoteMutationKind, RemoteMutationSpec,
};
File diff suppressed because it is too large. Load diff