diff options
author | Sami Hiltunen <shiltunen@gitlab.com> | 2021-07-29 14:31:01 +0300 |
---|---|---|
committer | Sami Hiltunen <shiltunen@gitlab.com> | 2021-07-30 18:08:10 +0300 |
commit | 5b2c9725b168b5dac3a3f818f812e838921b3f06 (patch) | |
tree | dc2891842934bd6a6f8eca878185f30cff52624d /cmd/praefect | |
parent | 339bb3994e584d06a7043f1b66a90e9a3774731d (diff) |
Create repository explicitly in SetReplicationFactor tests
SetGeneration should not create a repository record implicitly, only
the replicas record. This commit amends SetReplicationFactor tests to
create the repository record explicitly so we can change the behavior
of SetGeneration in a follow up commit.
Diffstat (limited to 'cmd/praefect')
-rw-r--r-- | cmd/praefect/subcmd_set_replication_factor_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmd/praefect/subcmd_set_replication_factor_test.go b/cmd/praefect/subcmd_set_replication_factor_test.go index 741bc8745..492c963dd 100644 --- a/cmd/praefect/subcmd_set_replication_factor_test.go +++ b/cmd/praefect/subcmd_set_replication_factor_test.go @@ -90,7 +90,7 @@ func TestSetReplicationFactorSubcommand(t *testing.T) { // create a repository record require.NoError(t, - datastore.NewPostgresRepositoryStore(db, nil).SetGeneration(ctx, "virtual-storage", "relative-path", "primary", 0), + datastore.NewPostgresRepositoryStore(db, nil).CreateRepository(ctx, "virtual-storage", "relative-path", "primary", nil, nil, false, false), ) ln, clean := listenAndServe(t, []svcRegistrar{registerPraefectInfoServer( |