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