Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

A Playwright Inbox Probe for Slow Email Tests

Описание и применение

Проба inbox в Playwright обеспечивает надёжное обнаружение письма подтверждения, устраняя случайные сбои, и сохраняет подробные данные для диагностики.

Задача

Email-driven browser tests often fail because the verification email is not found, leading to random failures due to clock drift between the application, worker, and mailbox API.

Результат

The probe reliably detects the verification email, reduces flaky failures, and records actionable evidence (run ID, mailbox, poll count, timestamps, inbox status, browser trace).

Рабочий процесс

  • Create a unique test mailbox address
  • Submit the sign‑up form
  • Poll the mailbox for a message addressed to the test address and containing a unique run ID
  • Return the message and polling metrics or throw an error if the deadline is exceeded

Доказательства

Email-driven browser tests often fail in the least helpful way: the registration form passes, but the test cannot find the verification message.

Источник

A reliable test needs more than a long timeout. It needs an inbox probe: a small, bounded workflow that proves which mailbox belongs to the test, polls for the expected message, and records enough evidence to explain a miss.

Источник

The sample keeps the deadline separate from the polling interval. That makes the behavior visible in code and easy to tune.

Источник

  • Дата записи: 2026-10-27T06:11:19.543Z