diff options
| author | Sandro Jäckel <sandro.jaeckel@sap.com> | 2023-04-17 14:43:15 +0200 |
|---|---|---|
| committer | Sandro Jäckel <sandro.jaeckel@sap.com> | 2023-04-17 14:56:16 +0200 |
| commit | d0059fcb87312d296a31d6965d6db84e499fe020 (patch) | |
| tree | ea285343822712bf002ad6dee0b11a094b442e2d /internal/rtree/get_test.go | |
| parent | 72c757b7a44dc5d19d821f7c2fa36bb082e4f2e3 (diff) | |
| download | gofu-d0059fcb87312d296a31d6965d6db84e499fe020.tar.gz | |
Only use compact URL in UI, not in written files
many tools like eg some vscode extensions can parse the git remotes but do not respect
git aliases and fail to understand shorthands like gh:majewsky/gofu
Diffstat (limited to 'internal/rtree/get_test.go')
| -rw-r--r-- | internal/rtree/get_test.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/internal/rtree/get_test.go b/internal/rtree/get_test.go index a438234..789e903 100644 --- a/internal/rtree/get_test.go +++ b/internal/rtree/get_test.go @@ -35,7 +35,7 @@ var testIndexWithTwoRepos = Index{ { CheckoutPath: "github.com/git/git", Remotes: []Remote{ - {Name: "origin", URL: "gh:git/git"}, + {Name: "origin", URL: "https://github.com/git/git"}, }, }, }, @@ -65,14 +65,14 @@ func TestGetNewRepo(t *testing.T) { Args: []string{"get", remoteURL}, Index: testIndexWithTwoRepos, ExpectOutput: target + "\n", - ExpectExecution: Recorded("git clone gh:another/repo " + target), + ExpectExecution: Recorded("git clone https://github.com/another/repo " + target), ExpectIndex: &Index{ Repos: []*Repo{ { CheckoutPath: "github.com/another/repo", Remotes: []Remote{ //regardless of the remote URL used, we expect the contracted form to be used - {Name: "origin", URL: "gh:another/repo"}, + {Name: "origin", URL: "https://github.com/another/repo"}, }, }, testIndexWithTwoRepos.Repos[0], @@ -106,7 +106,7 @@ func TestGetNewForkAsRemote(t *testing.T) { { CheckoutPath: "github.com/git/git", Remotes: []Remote{ - {Name: "origin", URL: "gh:git/git"}, + {Name: "origin", URL: "https://github.com/git/git"}, {Name: "myfork", URL: "https://example.com/git"}, }, }, |
