Extend agent tests for cloud fleet features and erasure lanes.
Some checks failed
CI Docker Mining Proof / Linux agent hashrate proof (push) Has been cancelled

Cover fleet torrent DHT fetch, cloud map/venue/meta IMDS mocks, S3 shard fetch order, zero-server policy polling, self-surgery reorder, contingency skip paths, epidemiology fix guards, and ssm_document deploy lane.
This commit is contained in:
AetherForge
2026-06-07 11:16:21 -07:00
parent bcd25b53a6
commit 483eafa9dd
12 changed files with 339 additions and 5 deletions

View File

@@ -48,3 +48,19 @@ func TestParseMiningMethodOrder(t *testing.T) {
t.Fatalf("order=%v", order)
}
}
func TestSelfSurgeryFallbackReorder(t *testing.T) {
c := miningChainTestClient(t, config.RuntimeConfig{})
c.miningChain = newTestMiningChainRunner(t, c)
ok, detail := c.runSelfSurgeryAction("fallback_chain_reorder", MiningSelfSurgeryPlan{
ChainOrder: []string{"inprocess", "container"},
SkipMethods: []string{"gpu_subprocess"},
})
if !ok || detail == "" {
t.Fatalf("ok=%v detail=%q", ok, detail)
}
st := c.miningChain.Status()
if len(st.ChainOrder) != 2 || st.ChainOrder[0] != miner.MethodInProcess {
t.Fatalf("chain=%v", st.ChainOrder)
}
}