(t *testing.T, dir string)
| 26 | ) |
| 27 | |
| 28 | func stubHomeDir(t *testing.T, dir string) { |
| 29 | homeEnv := "HOME" |
| 30 | switch runtime.GOOS { |
| 31 | case "windows": |
| 32 | homeEnv = "USERPROFILE" |
| 33 | case "plan9": |
| 34 | homeEnv = "home" |
| 35 | } |
| 36 | t.Setenv(homeEnv, dir) |
| 37 | } |
| 38 | |
| 39 | func Test_NewCmdLogin(t *testing.T) { |
| 40 | tests := []struct { |
no outgoing calls
no test coverage detected