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

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2021-03-01 12:48:53 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2021-03-01 12:48:53 +0300
commitbe99c5da09c2847ebd4b32584aba24448a394e8b (patch)
tree0cfd2370b4ee4fb9930b93bb557ff4e8a89857f8 /internal/praefect/info_service_test.go
parent141c3b4899804abd9d2bab26a5fe55497e54e1e8 (diff)
testhelper: Move repository helpers into `gittest`
It's currently not possible to use our git DSL in the testhelper package because of an import cycle between the testhelper and git package. To fix this import cycle, we thus move test-related git helpers into the gittest package. This commit moves the repository helpers. As we're already touching all sites which use these helpers anyway, it also aligns functions to have more consistent naming.
Diffstat (limited to 'internal/praefect/info_service_test.go')
-rw-r--r--internal/praefect/info_service_test.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/praefect/info_service_test.go b/internal/praefect/info_service_test.go
index bc8a17bff..76dd23e68 100644
--- a/internal/praefect/info_service_test.go
+++ b/internal/praefect/info_service_test.go
@@ -56,9 +56,9 @@ func TestInfoService_RepositoryReplicas(t *testing.T) {
Failover: config.Failover{Enabled: true},
}
- testRepo := testhelper.NewTestRepoTo(t, cfg.Storages[0].Path, "repo-1")
- testhelper.NewTestRepoTo(t, cfg.Storages[1].Path, "repo-1")
- testhelper.NewTestRepoTo(t, cfg.Storages[2].Path, "repo-1")
+ testRepo := gittest.CloneRepoAtStorageRoot(t, cfg.Storages[0].Path, "repo-1")
+ gittest.CloneRepoAtStorageRoot(t, cfg.Storages[1].Path, "repo-1")
+ gittest.CloneRepoAtStorageRoot(t, cfg.Storages[2].Path, "repo-1")
// create a commit in the second replica so we can check that its checksum is different than the primary
gittest.CreateCommit(t, filepath.Join(cfg.Storages[1].Path, "repo-1"), "master", nil)