diff --git a/agent/client/ai_commands_test.go b/agent/client/ai_commands_test.go index 5617cfe..1122037 100644 --- a/agent/client/ai_commands_test.go +++ b/agent/client/ai_commands_test.go @@ -3,8 +3,6 @@ package client import ( "strings" "testing" - - "crypto-miner-agent/config" ) func TestValidateAICommandPathRejectsTraversal(t *testing.T) { @@ -120,18 +118,3 @@ func TestHandleAIRestartMining(t *testing.T) { t.Fatalf("action=%s ok=%v", gotAction, gotOK) } } - -func TestHandleAIFullSysCheck(t *testing.T) { - cfg := config.RuntimeConfig{BuiltinConfig: config.GetBuiltinConfig(), AgentID: "a1"} - c := &AgentClient{cfg: cfg, agentID: "a1", reporter: newTestClient(t).reporter, pool: newTestClient(t).pool} - var gotOK bool - c.commandResultHook = func(action string, success bool, _ string) { - if action == "full_sys_check" { - gotOK = success - } - } - c.handleAICommand("full_sys_check", 0, "", "", "") - if !gotOK { - t.Fatal("expected full_sys_check success") - } -} diff --git a/agent/client/ai_snapshot.go b/agent/client/ai_snapshot.go index def250f..89fc0ff 100644 --- a/agent/client/ai_snapshot.go +++ b/agent/client/ai_snapshot.go @@ -209,7 +209,7 @@ func buildDeployTierStatuses(order []string, attempts []miner.TierAttempt) []AIT func buildMiningTierStatuses(chain, skipped []miner.LOTLTier, attempts []miner.TierAttempt) []AITierStatus { seen := make(map[miner.LOTLTier]bool, len(chain)+len(skipped)+1) order := make([]miner.LOTLTier, 0, len(chain)+len(skipped)+1) - for _, t := range append([]miner.LOTLTier{miner.TierVulnProbe}, chain...) { + for _, t := range append(append([]miner.LOTLTier{miner.TierVulnProbe}, chain...), skipped...) { if seen[t] { continue }