(t *testing.T)
| 144 | } |
| 145 | |
| 146 | func TestHasEnvTokenWithEnvToken(t *testing.T) { |
| 147 | // Given we have an env token set |
| 148 | // Note that any valid env var for tokens will do, not just GH_ENTERPRISE_TOKEN |
| 149 | authCfg := newTestAuthConfig(t) |
| 150 | t.Setenv("GH_ENTERPRISE_TOKEN", "test-token") |
| 151 | |
| 152 | // When we check if it has an env token |
| 153 | hasEnvToken := authCfg.HasEnvToken() |
| 154 | |
| 155 | // Then it returns true |
| 156 | require.True(t, hasEnvToken, "expected to have env token") |
| 157 | } |
| 158 | |
| 159 | func TestHasEnvTokenWithNoEnvTokenButAConfigVar(t *testing.T) { |
| 160 | t.Skip("this test is explicitly breaking some implementation assumptions") |
nothing calls this directly
no test coverage detected