Add phenotype cloning, failure atlas, AI court session, and clearance L0-L4
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
This commit is contained in:
@@ -158,6 +158,44 @@ func TestSelectMiningTierChainForceTier(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestSelectMiningTierChainAtlasSkipOmitsTier(t *testing.T) {
|
||||
policy := MiningTierPolicy{
|
||||
TierOrder: DefaultTierOrder,
|
||||
SkipTiers: []LOTLTier{TierPSInMemory},
|
||||
}
|
||||
chain, skipped := SelectMiningTierChain(baseProbes(), policy, testCfg(config.BuiltinConfig{}))
|
||||
if chainContains(chain, TierPSInMemory) {
|
||||
t.Fatalf("atlas/policy skip should omit ps_inmemory from chain=%v", chain)
|
||||
}
|
||||
if !chainContains(skipped, TierPSInMemory) {
|
||||
t.Fatalf("expected ps_inmemory in skipped=%v", skipped)
|
||||
}
|
||||
}
|
||||
|
||||
func TestTierOrchestratorAtlasSkipNotAttempted(t *testing.T) {
|
||||
probes := baseProbes()
|
||||
policy := MiningTierPolicy{
|
||||
TierOrder: []LOTLTier{TierPSInMemory, TierCPUInprocess},
|
||||
SkipTiers: []LOTLTier{TierPSInMemory},
|
||||
}
|
||||
o := NewTierOrchestrator(testCfg(config.BuiltinConfig{}), probes, policy, TierHooks{
|
||||
StartInProcess: func() error { return nil },
|
||||
}, nil)
|
||||
|
||||
tier, err := o.TryChain(t.Context())
|
||||
if err != nil {
|
||||
t.Fatalf("TryChain: %v", err)
|
||||
}
|
||||
if tier != TierCPUInprocess {
|
||||
t.Fatalf("active=%q want cpu_inprocess", tier)
|
||||
}
|
||||
for _, a := range o.Report().Attempts {
|
||||
if a.Tier == TierPSInMemory {
|
||||
t.Fatalf("atlas-skipped tier should not be attempted: %+v", a)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestTierOrchestratorStubTiersFallThrough(t *testing.T) {
|
||||
probes := EnvironmentProbes{
|
||||
Docker: false,
|
||||
|
||||
Reference in New Issue
Block a user