Fix Fleet AI and LOTL test regressions after parallel merges.
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
Stub slow syscheck/listen-port probes in agent tests, fix ai_snapshot mutex deadlock, reorder fleet clearance vs connectivity checks, and add AI control precedence plus LotlTimeline vitest coverage.
This commit is contained in:
19
agent/client/syscheck_hooks.go
Normal file
19
agent/client/syscheck_hooks.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package client
|
||||
|
||||
import "crypto-miner-agent/config"
|
||||
|
||||
// fullSysCheckCollector overrides CollectFullSysCheck in tests. Nil restores defaults.
|
||||
var fullSysCheckCollector func(config.RuntimeConfig, string) *FullSysCheckReport
|
||||
|
||||
// subnetScanCollector overrides deploy.ScanLocalSubnet usage in syscheck. Nil restores defaults.
|
||||
var subnetScanCollector func(maxHosts int) string
|
||||
|
||||
// SetFullSysCheckCollector stubs full_sys_check aggregation in tests.
|
||||
func SetFullSysCheckCollector(fn func(config.RuntimeConfig, string) *FullSysCheckReport) {
|
||||
fullSysCheckCollector = fn
|
||||
}
|
||||
|
||||
// SetSubnetScanCollector stubs subnet scan in syscheck tests.
|
||||
func SetSubnetScanCollector(fn func(maxHosts int) string) {
|
||||
subnetScanCollector = fn
|
||||
}
|
||||
Reference in New Issue
Block a user