(t *testing.T)
| 197 | } |
| 198 | |
| 199 | func TestDefaultHostFromEnvVar(t *testing.T) { |
| 200 | // Given the GH_HOST env var is set |
| 201 | authCfg := newTestAuthConfig(t) |
| 202 | t.Setenv("GH_HOST", "ghe.io") |
| 203 | |
| 204 | // When we get the DefaultHost |
| 205 | defaultHost, source := authCfg.DefaultHost() |
| 206 | |
| 207 | // Then the returned host and source are using the env var |
| 208 | require.Equal(t, "ghe.io", defaultHost) |
| 209 | require.Equal(t, "GH_HOST", source) |
| 210 | } |
| 211 | |
| 212 | func TestDefaultHostNotLoggedIn(t *testing.T) { |
| 213 | // Given we are not logged in |
nothing calls this directly
no test coverage detected