(t *testing.T)
| 7 | ) |
| 8 | |
| 9 | func TestWindowsCmdExe_ComSpec(t *testing.T) { |
| 10 | t.Setenv("ComSpec", `C:\Custom\cmd.exe`) |
| 11 | got := WindowsCmdExe() |
| 12 | if got != `C:\Custom\cmd.exe` { |
| 13 | t.Errorf("WindowsCmdExe() = %q, want %q", got, `C:\Custom\cmd.exe`) |
| 14 | } |
| 15 | } |
| 16 | |
| 17 | func TestWindowsCmdExe_SystemRoot(t *testing.T) { |
| 18 | t.Setenv("ComSpec", "") |
nothing calls this directly
no test coverage detected