Assert the controller's buckets before the served test's fixture writes the chain (issue 1945)

This commit is contained in:
2026-10-24 19:09:54 +02:00
parent 4ab4529440
commit a78f244621
@@ -148,6 +148,15 @@ func aServedMesh(t *testing.T) *servedMesh {
t.Fatal(err)
}
t.Cleanup(chainConn.Close)
// The controller's own buckets, the chain's among them, as it asserts them at its start.
asserter, err := broker.Dial(u.String())
if err != nil {
t.Fatal(err)
}
t.Cleanup(asserter.Close)
if err := asserter.EnsureControllerBuckets(); err != nil {
t.Fatalf("the controller's buckets: %v", err)
}
c, err := chain.OnTheBus(ctx, chainConn, func(context.Context) error { return nil })
if err != nil {
t.Fatal(err)