(t *testing.T)
| 301 | } |
| 302 | |
| 303 | func TestLoginSetsUserForProvidedHost(t *testing.T) { |
| 304 | // Given we are not logged in |
| 305 | authCfg := newTestAuthConfig(t) |
| 306 | |
| 307 | // When we login |
| 308 | _, err := authCfg.Login("github.com", "test-user", "test-token", "ssh", false) |
| 309 | |
| 310 | // Then it returns success and the user is set |
| 311 | require.NoError(t, err) |
| 312 | |
| 313 | user, err := authCfg.ActiveUser("github.com") |
| 314 | require.NoError(t, err) |
| 315 | require.Equal(t, "test-user", user) |
| 316 | } |
| 317 | |
| 318 | func TestLoginSetsGitProtocolForProvidedHost(t *testing.T) { |
| 319 | // Given we are logged in |
nothing calls this directly
no test coverage detected