Read the tested nats release from the server itself
mesh/merge-gate pass: builds nats, sent nowhere; a bus step; 1 wait(s) for a person; every machine composes with the change as it did without (4 of 4 compo…
mesh/repo-check pass: its merge-check.sh passed
mesh/delivery delivered
mesh/delivery-group group fix/327-a-verb-reads-on-the-serving-connection delivered: every member is delivered

The build seat's test binary listed no dependencies, so the check that the
image and the tests run one release failed on a release that matched.
This commit is contained in:
jochen
2026-10-08 18:07:29 +02:00
parent 0063cc2ad1
commit ea69e795ab
+4 -13
View File
@@ -7,7 +7,6 @@ import (
"net/http"
"os"
"regexp"
"runtime/debug"
"sync"
"testing"
"time"
@@ -28,19 +27,11 @@ func TestTheImageIsTheServerTestedHere(t *testing.T) {
if said == nil {
t.Fatal("the Dockerfile does not say which nats release its digest is (`# upstream: nats X.Y.Z-alpine`)")
}
info, ok := debug.ReadBuildInfo()
if !ok {
t.Fatal("no build information to read the tested server's version from")
// The server's own word for its release, compiled into it: a test binary's build information may list
// no dependencies (the build seat's did not, so this read "these tests run no nats-server").
if server.VERSION != string(said[1]) {
t.Fatalf("the image runs nats %s and these tests run %s: move them together", said[1], server.VERSION)
}
for _, dep := range info.Deps {
if dep.Path == "github.com/nats-io/nats-server/v2" {
if dep.Version != "v"+string(said[1]) {
t.Fatalf("the image runs nats %s and these tests run %s: move them together", said[1], dep.Version)
}
return
}
}
t.Fatal("these tests run no nats-server")
}
// **A consumer with several filters is handed every message** (novox/hq issue 266).