diff options
author | Pavlo Strokov <pstrokov@gitlab.com> | 2020-11-08 18:24:31 +0300 |
---|---|---|
committer | Pavlo Strokov <pstrokov@gitlab.com> | 2020-11-20 13:07:13 +0300 |
commit | a874e075ed161671d4eb91a57e0dd4d9b2e4a610 (patch) | |
tree | ed5bf9af1edbdf47d954ba27c0c9ef15f2720483 /internal/praefect/info_service_test.go | |
parent | 9191f8f0f17d3b7a958424f91527aa8d8b4c3fcb (diff) |
Unbound initialization and validation funcs from global Config
In order to remove dependency on the global config.Config var we
need to break dependencies between Config and it's initialization
and validation functions. Most of them now represented as a methods
on the config.Cfg type. It allows us to setup required Cfg struct
for the tests to run without need to sync changes done on the
shared global Config var. The tests that were heavily dependent
on the Config var now depend on the struct initialized inside
the test instead.
Part of: https://gitlab.com/gitlab-org/gitaly/-/issues/2699
Blocks: https://gitlab.com/gitlab-org/gitaly/-/issues/3166
Diffstat (limited to 'internal/praefect/info_service_test.go')
-rw-r--r-- | internal/praefect/info_service_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/praefect/info_service_test.go b/internal/praefect/info_service_test.go index 8d59575bd..625e6428c 100644 --- a/internal/praefect/info_service_test.go +++ b/internal/praefect/info_service_test.go @@ -50,7 +50,7 @@ func TestInfoService_RepositoryReplicas(t *testing.T) { testRepo, _, cleanup := testhelper.NewTestRepo(t) defer cleanup() - cc, _, cleanup := runPraefectServerWithGitaly(t, conf) + cc, _, cleanup := runPraefectServerWithGitaly(t, gconfig.Config, conf) defer cleanup() testRepoPrimary, _, cleanup := cloneRepoAtStorage(t, testRepo, conf.VirtualStorages[0].Nodes[0].Storage) |