(t *testing.T)
| 34 | } |
| 35 | |
| 36 | func TestReadUint(t *testing.T) { |
| 37 | tDir := t.TempDir() |
| 38 | pidsmax := filepath.Join(tDir, "pids.max") |
| 39 | err := os.WriteFile(pidsmax, []byte("max"), 0644) |
| 40 | if err != nil { |
| 41 | t.Fatal(err) |
| 42 | } |
| 43 | max, err := readUint(pidsmax) |
| 44 | if err != nil { |
| 45 | t.Fatal(err) |
| 46 | } |
| 47 | // test for backwards compatibility |
| 48 | if max != 0 { |
| 49 | t.Fail() |
| 50 | } |
| 51 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…