Test that node-tools' manifest is not refused by the lease write's check (ADR 0571 §13)

Tests: one added, the first of its kind in this repository; the repository holds 128 unit tests, within its budget of 500.
Built against the group's mesh-sdk through a go.work outside the tree; go.mod is not re-pinned here.

(issue 774, 774/S33)
Claude-Session: https://claude.ai/code/session_01NcbgfJ9Gum47zkFKWRaovL
This commit is contained in:
2026-11-02 00:26:04 +01:00
parent 4fbfdfad13
commit 5b2ff5e321
@@ -194,3 +194,19 @@ func TestOnlyTheMachinesRuntimeStartsTheHelper(t *testing.T) {
Start(nil, c.module, c.node, time.Second, said.Logf)()
}
}
// 774/S33 (ADR 0571 clause 13): this manifest, read as the lease write's check reads it, is not refused at the write: it
// reads and invokes nothing of the controller and consumes nothing of it.
func TestTheManifestIsNotRefusedAtTheLeaseWrite(t *testing.T) {
raw, err := os.ReadFile("../../module.json")
if err != nil {
t.Fatal(err)
}
m, err := catalogue.Decode(raw)
if err != nil {
t.Fatal(err)
}
if refused := catalogue.ManifestRefusals(map[string]catalogue.Manifest{Module: m}, catalogue.PhaseWrite); len(refused) != 0 {
t.Errorf("the lease write's check refuses node-tools' manifest: %v", refused)
}
}