Skip to content

Commit

Permalink
fix e2e test for gitlab
Browse files Browse the repository at this point in the history
Signed-off-by: Somtochi Onyekwere <[email protected]>
  • Loading branch information
somtochiama committed Oct 11, 2023
1 parent 2e5501f commit 7875e62
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions gitlab/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -807,12 +807,10 @@ var _ = Describe("GitLab Provider", func() {
repoName := fmt.Sprintf("test-user-repo-creation-%03d", rand.Intn(1000))
repoRef := newUserRepoRef(testBaseUrl, "yadda-yadda-yada", repoName)

repo, err := c.UserRepositories().Create(ctx, repoRef, gitprovider.RepositoryInfo{})
_, err := c.UserRepositories().Create(ctx, repoRef, gitprovider.RepositoryInfo{})

Expect(err).To(BeNil())
Expect(
repo.Repository().GetCloneURL(gitprovider.TransportTypeHTTPS)).
To(Equal(fmt.Sprintf("%s/%s/%s.git", testBaseUrl, testUserName, repoName)))
expectedErr := fmt.Errorf("incorrect owner '%s' passed in", repoRef.UserLogin)
Expect(err).To(MatchError(expectedErr))
})

It("should update if the user repo already exists when reconciling", func() {
Expand Down

0 comments on commit 7875e62

Please sign in to comment.