test(e2e): follow send-log status badge markup in scrapers
test / test (push) Has been cancelled

The deliveries_rows template wraps status in badge spans, but the e2e gate still looked for bare td cells, so send_verify_dkim_and_status timed out even when mail was delivered and logged. Add a handler regression test so go test ./... catches this drift without Docker.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-13 14:19:31 +03:00
parent a1e7e05d26
commit 6216e430e9
2 changed files with 48 additions and 2 deletions
+2 -2
View File
@@ -19,7 +19,7 @@ import (
"time"
)
var statusCellPattern = regexp.MustCompile(`<td>(queued|sent|deferred|bounced|rejected)</td>`)
var statusCellPattern = regexp.MustCompile(`class="st st-[^"]+">(queued|sent|deferred|bounced|rejected)</span>`)
// h is the single shared stand for the whole ordered scenario in TestE2E.
// TestHostnameGate does not use it — it spins its own disposable container.
@@ -247,7 +247,7 @@ func uniqueToken(label string) string {
}
func containsCell(html, needle string) bool {
return strings.Contains(html, "<td>"+needle+"</td>")
return strings.Contains(html, `<span class="st st-`) && strings.Contains(html, `">`+needle+`</span>`)
}
func firstStatusCell(html string) string {