Skip to content

Commit

Permalink
Avoid inheriting stderr in SelectiveExecutionTests.scala to prevent…
Browse files Browse the repository at this point in the history
… flakiness from leaked processes (#4581)

Currently, the inherited `stderr` can remain open even as the spawned
processes are killed, causing the test to hang on waiting for the
`stderr` to close. This avoids inheriting stderr, so once the spawned
processes dies the test can terminate cleanly
  • Loading branch information
lihaoyi authored Feb 18, 2025
1 parent 233664f commit c3ec8da
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ object SelectiveExecutionWatchTests extends UtestIntegrationTestSuite {
("--watch", "{foo.fooCommand,bar.barCommand}"),
check = true,
stdout = os.ProcessOutput.Readlines { line => output0 = output0 :+ line },
stderr = os.Inherit
stderr = os.ProcessOutput.Readlines { line => System.err.println(line) }
)
}

Expand Down

0 comments on commit c3ec8da

Please sign in to comment.