Skip to content

Commit 7275ef7

Browse files
committed
Update configs_test.go
1 parent e29f559 commit 7275ef7

File tree

1 file changed

+0
-47
lines changed

1 file changed

+0
-47
lines changed

configs/configs_test.go

Lines changed: 0 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -97,53 +97,6 @@ func TestVerifyConfigsSetCorrectly(t *testing.T) {
9797
})
9898
}
9999

100-
func TestVerifyTrialingSlashes(t *testing.T) {
101-
102-
t.Run("When cloning github", func(tt *testing.T) {
103-
os.Setenv("GHORG_SCM_TYPE", "github")
104-
os.Setenv("GHORG_GITHUB_TOKEN", "")
105-
106-
err := configs.VerifyTokenSet()
107-
if err != configs.ErrNoGitHubToken {
108-
tt.Errorf("Expected ErrNoGitHubTokenError, got: %v", err)
109-
}
110-
111-
})
112-
113-
t.Run("When cloning gitlab", func(tt *testing.T) {
114-
os.Setenv("GHORG_SCM_TYPE", "gitlab")
115-
os.Setenv("GHORG_GITLAB_TOKEN", "")
116-
117-
err := configs.VerifyTokenSet()
118-
if err != configs.ErrNoGitLabToken {
119-
tt.Errorf("Expected ErrNoGitLabTokenError, got: %v", err)
120-
}
121-
122-
})
123-
124-
t.Run("When cloning bitbucket with no username", func(tt *testing.T) {
125-
os.Setenv("GHORG_SCM_TYPE", "bitbucket")
126-
os.Setenv("GHORG_BITBUCKET_USERNAME", "")
127-
os.Setenv("GHORG_BITBUCKET_APP_PASSWORD", "12345678912345678901")
128-
err := configs.VerifyTokenSet()
129-
if err != configs.ErrNoBitbucketUsername {
130-
tt.Errorf("Expected ErrNoBitbucketUsername, got: %v", err)
131-
}
132-
133-
})
134-
135-
t.Run("When cloning bitbucket with username but no app password", func(tt *testing.T) {
136-
os.Setenv("GHORG_SCM_TYPE", "bitbucket")
137-
os.Setenv("GHORG_BITBUCKET_USERNAME", "bitbucketuser")
138-
os.Setenv("GHORG_BITBUCKET_APP_PASSWORD", "")
139-
err := configs.VerifyTokenSet()
140-
if err != configs.ErrNoBitbucketAppPassword {
141-
tt.Errorf("Expected ErrNoBitbucketAppPassword, got: %v", err)
142-
}
143-
144-
})
145-
}
146-
147100
func TestTrailingSlashes(t *testing.T) {
148101
t.Run("URL's with no trailing slash should get one", func(tt *testing.T) {
149102
got := configs.EnsureTrailingSlashOnURL("github.com")

0 commit comments

Comments
 (0)