1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-10-17 20:31:19 +03:00

Close the pty instead of killing the process for runAndDetectCredentialRequest

As with the previous commit, this is not strictly necessary for anything, just
cleaner.
This commit is contained in:
Stefan Haller
2025-07-29 10:43:42 +02:00
parent 83046a05d4
commit 7d9eaead54
2 changed files with 21 additions and 19 deletions

View File

@@ -127,7 +127,7 @@ func TestProcessOutput(t *testing.T) {
writer := &strings.Builder{}
cmdObj := &CmdObj{task: gocui.NewFakeTask()}
runner.processOutput(reader, writer, toChanFn(scenario.promptUserForCredential), cmdObj)
runner.processOutput(reader, writer, toChanFn(scenario.promptUserForCredential), func() error { return nil }, cmdObj)
if writer.String() != scenario.expectedToWrite {
t.Errorf("expected to write '%s' but got '%s'", scenario.expectedToWrite, writer.String())