e2e: the queues as tables - a deferred message on each, the empty one

- queue_readable_by_the_panel: the empty queue says "Nothing is waiting" (it
  read postqueue -p's "Mail queue is empty").
- expired_message_is_closed: while defer_transports holds the message,
  Outbound › Queue lists it with Postfix's reason ("deferred transport",
  qmgr_message.c) and a Details link to its row.
- inbound_relay_delivers_and_refuses (testInboundUpstreamDown): the message
  for an upstream that refuses is on Inbound › Queue with "connect to
  10.77.0.11[10.77.0.11]:2526: Connection refused", and not on Outbound ›
  Queue.

make e2e on the test server for 6db3704 plus this: 65 passed, 0 failed;
go vet + go test there: 26 packages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
mix
2026-10-18 23:35:50 +03:00
co-authored by Claude Opus 5.5
parent 6edf8314bc
commit 853e0cabf3
3 changed files with 30 additions and 3 deletions
+11
View File
@@ -136,6 +136,17 @@ print("" if r is None else r[0]+" "+r[1])`, token)
t.Fatal(err)
}
// Outbound › Queue lists the waiting recipient, with Postfix's reason and
// the link to its row in the Outbound log (postqueue -j, as the panel).
_, body, err := sc.panel.get("/outbound/queue")
if err != nil {
t.Fatal(err)
}
if !strings.Contains(body, `<td class="sp-mono">`+queueID+`</td>`) || !regexp.MustCompile(`<td class="sp-muted">[^<]*deferred transport</td>`).MatchString(body) ||
!regexp.MustCompile(`<td class="sp-actions"><a href="/outbound/log/\d+">Details</a></td>`).MatchString(body) {
t.Fatalf("Outbound › Queue does not list the deferred message %s with its reason and row:\n%.4000s", queueID, body)
}
exec("postsuper", "-e", queueID)
exec("postqueue", "-i", queueID)
if err := waitFor("the expired message's row to be bounced", 30*time.Second, 500*time.Millisecond, func() (bool, error) {