Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-pages.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'internal/source/gitlab/gitlab_test.go')
-rw-r--r--internal/source/gitlab/gitlab_test.go7
1 files changed, 3 insertions, 4 deletions
diff --git a/internal/source/gitlab/gitlab_test.go b/internal/source/gitlab/gitlab_test.go
index 0b6488fe..0e855f10 100644
--- a/internal/source/gitlab/gitlab_test.go
+++ b/internal/source/gitlab/gitlab_test.go
@@ -6,14 +6,13 @@ import (
"github.com/stretchr/testify/require"
- "gitlab.com/gitlab-org/gitlab-pages/internal/source/gitlab/cache"
"gitlab.com/gitlab-org/gitlab-pages/internal/source/gitlab/client"
)
func TestGetDomain(t *testing.T) {
t.Run("when the response if correct", func(t *testing.T) {
client := client.StubClient{File: "client/testdata/test.gitlab.io.json"}
- source := Gitlab{client: client, cache: cache.New()}
+ source := Gitlab{client: client}
domain, err := source.GetDomain("test.gitlab.io")
require.NoError(t, err)
@@ -23,7 +22,7 @@ func TestGetDomain(t *testing.T) {
t.Run("when the response is not valid", func(t *testing.T) {
client := client.StubClient{File: "/dev/null"}
- source := Gitlab{client: client, cache: cache.New()}
+ source := Gitlab{client: client}
domain, err := source.GetDomain("test.gitlab.io")
@@ -34,7 +33,7 @@ func TestGetDomain(t *testing.T) {
func TestResolve(t *testing.T) {
client := client.StubClient{File: "client/testdata/test.gitlab.io.json"}
- source := Gitlab{client: client, cache: cache.New()}
+ source := Gitlab{client: client}
t.Run("when requesting nested group project with root path", func(t *testing.T) {
target := "https://test.gitlab.io:443/my/pages/project/"