Skip to content

Commit 2516035

Browse files
committed
address review comment
1 parent 3a20cee commit 2516035

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

utils/subprocess/executor_test.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,6 +397,7 @@ func TestExecute(t *testing.T) {
397397
}
398398

399399
func TestStart(t *testing.T) {
400+
400401
currentDir, err := os.Getwd()
401402
require.NoError(t, err)
402403

@@ -428,7 +429,7 @@ func TestStart(t *testing.T) {
428429

429430
for _, test := range tests {
430431
t.Run(test.name, func(t *testing.T) {
431-
// defer goleak.VerifyNone(t)
432+
defer goleak.VerifyNone(t)
432433

433434
customIO := newTestIO()
434435
executors := []struct {
@@ -460,7 +461,9 @@ func TestStart(t *testing.T) {
460461
}
461462
require.NoError(t, err)
462463
require.NotNil(t, p)
464+
defer func() { _ = p.Stop() }()
463465
require.NoError(t, p.Wait(context.Background()))
466+
p.Cancel()
464467
})
465468
}
466469
})

0 commit comments

Comments
 (0)