package client import ( "context" "testing" "time" "crypto-miner-agent/config" ) func TestMiningChainSkipsWhenSeederRole(t *testing.T) { setupNoContainerRuntime(t) cfg := baseMiningCfg() cfg.SeederMode = true cfg.FleetRole = config.FleetRoleSeeder c := miningChainTestClient(t, cfg) c.connected.Store(true) c.miningChain = newTestMiningChainRunner(t, c) ctx, cancel := context.WithTimeout(context.Background(), 200*time.Millisecond) defer cancel() c.startMiningWhenReady(ctx) if r := c.miningChain.Status(); r.ActiveMethod != "" { t.Fatalf("seeder should not start chain, active=%q", r.ActiveMethod) } }