mirror of
https://git.vectorsigma.ru/public/atlantis.git
synced 2026-08-02 10:48:44 +00:00
Fix parse URL tests
This commit is contained in:
@@ -610,7 +610,7 @@ func TestExecute_BitbucketServerBaseURLScheme(t *testing.T) {
|
||||
RepoWhitelistFlag: "*",
|
||||
BitbucketBaseURLFlag: "://mydomain.com",
|
||||
})
|
||||
ErrEquals(t, "error parsing --bitbucket-webhook-secret flag value \"://mydomain.com\": parse ://mydomain.com: missing protocol scheme", c.Execute())
|
||||
ErrEquals(t, "error parsing --bitbucket-webhook-secret flag value \"://mydomain.com\": parse \"://mydomain.com\": missing protocol scheme", c.Execute())
|
||||
}
|
||||
|
||||
// Port should be retained on base url.
|
||||
|
||||
@@ -35,7 +35,7 @@ func TestNewRepo_EmptyCloneURL(t *testing.T) {
|
||||
|
||||
func TestNewRepo_InvalidCloneURL(t *testing.T) {
|
||||
_, err := models.NewRepo(models.Github, "owner/repo", ":", "u", "p")
|
||||
ErrEquals(t, "invalid clone url: parse :.git: missing protocol scheme", err)
|
||||
ErrEquals(t, "invalid clone url: parse \":.git\": missing protocol scheme", err)
|
||||
}
|
||||
|
||||
func TestNewRepo_CloneURLWrongRepo(t *testing.T) {
|
||||
|
||||
@@ -217,7 +217,7 @@ func TestParseAtlantisURL(t *testing.T) {
|
||||
// Must be valid URL.
|
||||
{
|
||||
In: "::",
|
||||
ExpErr: "parse ::: missing protocol scheme",
|
||||
ExpErr: "parse \"::\": missing protocol scheme",
|
||||
},
|
||||
|
||||
// Must be absolute.
|
||||
|
||||
Reference in New Issue
Block a user