(t *testing.T)
| 703 | } |
| 704 | |
| 705 | func TestGitProtocolWorksRightAfterMigration(t *testing.T) { |
| 706 | // Given we have logged in before migration with a non-default git protocol |
| 707 | authCfg := newTestAuthConfig(t) |
| 708 | _, err := preMigrationLogin(authCfg, "github.com", "test-user", "test-token", "ssh", false) |
| 709 | require.NoError(t, err) |
| 710 | |
| 711 | // When we migrate |
| 712 | var m migration.MultiAccount |
| 713 | c := cfg{authCfg.cfg} |
| 714 | require.NoError(t, c.Migrate(m)) |
| 715 | |
| 716 | // Then we can still get the git protocol correctly |
| 717 | gitProtocol, err := authCfg.cfg.Get([]string{hostsKey, "github.com", gitProtocolKey}) |
| 718 | require.NoError(t, err) |
| 719 | require.Equal(t, "ssh", gitProtocol) |
| 720 | } |
| 721 | |
| 722 | func TestHostsWorksRightAfterMigration(t *testing.T) { |
| 723 | // Given we have logged in before migration |
nothing calls this directly
no test coverage detected