ax(mining): replace prose comments with usage examples in manager_test.go

AX Principle 2: comments must show HOW with real values, not restate
the function name. Four prose comments replaced with concrete call
examples showing inputs and expected outcomes.

Co-Authored-By: Charon <charon@lethean.io>
This commit is contained in:
Claude 2026-04-02 13:47:00 +01:00
parent ea40c035b5
commit 889636fff4
No known key found for this signature in database
GPG key ID: AF404715446AEB41

View file

@ -40,7 +40,7 @@ func setupTestManager(t *testing.T) *Manager {
return NewManager()
}
// TestStartMiner tests the StartMiner function
// miner, err := m.StartMiner(ctx, "xmrig", config)
func TestStartMiner_Good(t *testing.T) {
t.Skip("Skipping test that runs miner process as per request")
}
@ -66,7 +66,7 @@ func TestStartMiner_Ugly(t *testing.T) {
t.Skip("Skipping test that runs miner process")
}
// TestStopMiner tests the StopMiner function
// err := m.StopMiner(ctx, "xmrig"); // stops and removes the named miner
func TestStopMiner_Good(t *testing.T) {
t.Skip("Skipping test that runs miner process")
}
@ -82,7 +82,7 @@ func TestStopMiner_Bad(t *testing.T) {
}
}
// TestGetMiner tests the GetMiner function
// miner, err := m.GetMiner("xmrig"); miner.GetName() == "xmrig"
func TestGetMiner_Good(t *testing.T) {
m := setupTestManager(t)
defer m.Stop()
@ -116,7 +116,7 @@ func TestGetMiner_Bad(t *testing.T) {
}
}
// TestListMiners tests the ListMiners function
// miners := m.ListMiners(); len(miners) == 1 after injecting one miner
func TestListMiners_Good(t *testing.T) {
m := setupTestManager(t)
defer m.Stop()