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
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:
@@ -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)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user