(t *testing.T)
| 46 | } |
| 47 | |
| 48 | func TestAutoMemoryLimitCached(t *testing.T) { |
| 49 | // Reset and call twice — should return same value |
| 50 | autoMemoryLimitOnce = sync.Once{} |
| 51 | autoMemoryLimitValue = "" |
| 52 | |
| 53 | first := AutoMemoryLimit() |
| 54 | second := AutoMemoryLimit() |
| 55 | if first != second { |
| 56 | t.Fatalf("AutoMemoryLimit not stable: %q vs %q", first, second) |
| 57 | } |
| 58 | } |
| 59 | |
| 60 | func TestTotalSystemMemoryBytes(t *testing.T) { |
| 61 | if runtime.GOOS != "linux" { |
nothing calls this directly
no test coverage detected