From dc0f6d55e26709ccb75f3718c4a611ca64a34280 Mon Sep 17 00:00:00 2001 From: William Martin Date: Fri, 1 Dec 2023 15:18:51 +0100 Subject: [PATCH] Use real config in fork cmd tests --- pkg/cmd/repo/fork/fork_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/cmd/repo/fork/fork_test.go b/pkg/cmd/repo/fork/fork_test.go index c0aa32bbd..e85558597 100644 --- a/pkg/cmd/repo/fork/fork_test.go +++ b/pkg/cmd/repo/fork/fork_test.go @@ -211,7 +211,7 @@ func TestRepoFork(t *testing.T) { httpStubs func(*httpmock.Registry) execStubs func(*run.CommandStubber) promptStubs func(*prompter.MockPrompter) - cfgStubs func(*config.ConfigMock) + cfgStubs func(config.Config) remotes []*context.Remote wantOut string wantErrOut string @@ -254,7 +254,7 @@ func TestRepoFork(t *testing.T) { Repo: ghrepo.New("OWNER", "REPO"), }, }, - cfgStubs: func(c *config.ConfigMock) { + cfgStubs: func(c config.Config) { c.Set("", "git_protocol", "") }, httpStubs: forkPost, @@ -731,7 +731,7 @@ func TestRepoFork(t *testing.T) { return &http.Client{Transport: reg}, nil } - cfg := config.NewBlankConfig() + cfg, _ := config.NewIsolatedTestConfig(t) if tt.cfgStubs != nil { tt.cfgStubs(cfg) }