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>2022-08-10 10:35:39 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2022-08-11 13:35:45 +0300
commit235963e94dbf75d716d2b23360120504f45d9f26 (patch)
treef79f05f42a4e2297a00da9d93eeff455df7410ee /internal/cache
parent24a3bead79daada06a70d58465cbf9fa9f38954b (diff)
gittest: Convert callers of CloneRepo to use CreateRepository
Convert all callers of CloneRepo to use CreateRepository.
Diffstat (limited to 'internal/cache')
-rw-r--r--internal/cache/diskcache_test.go15
1 files changed, 11 insertions, 4 deletions
diff --git a/internal/cache/diskcache_test.go b/internal/cache/diskcache_test.go
index be58460ba..b33ad8648 100644
--- a/internal/cache/diskcache_test.go
+++ b/internal/cache/diskcache_test.go
@@ -47,8 +47,17 @@ func TestStreamDBNaiveKeyer(t *testing.T) {
cfg := testcfg.Build(t)
- repo1, _ := gittest.CloneRepo(t, cfg, cfg.Storages[0])
- repo2, _ := gittest.CloneRepo(t, cfg, cfg.Storages[0])
+ ctx := testhelper.Context(t)
+ ctx = testhelper.SetCtxGrpcMethod(ctx, "InfoRefsUploadPack")
+
+ repo1, _ := gittest.CreateRepository(ctx, t, cfg, gittest.CreateRepositoryConfig{
+ SkipCreationViaService: true,
+ Seed: gittest.SeedGitLabTest,
+ })
+ repo2, _ := gittest.CreateRepository(ctx, t, cfg, gittest.CreateRepositoryConfig{
+ SkipCreationViaService: true,
+ Seed: gittest.SeedGitLabTest,
+ })
locator := config.NewLocator(cfg)
@@ -58,8 +67,6 @@ func TestStreamDBNaiveKeyer(t *testing.T) {
req2 := &gitalypb.InfoRefsRequest{
Repository: repo2,
}
- ctx := testhelper.Context(t)
- ctx = testhelper.SetCtxGrpcMethod(ctx, "InfoRefsUploadPack")
t.Run("empty cache", func(t *testing.T) {
cache := New(cfg, locator)