web icon indicating copy to clipboard operation
web copied to clipboard

test-runner-core always emits ansi codes to clear progress bars, even if there aren't progress bars

Open MSLaguana opened this issue 1 year ago • 0 comments

The @web/test-runner-core package includes the TestRunnerCli class, which always has a DynamicTerminal that it references that has no knowledge of the staticLogging configuration variable. The TestRunnerCli will do things like decide not to print progress, but the DynamicTerminal will always try to clear the console via https://github.com/modernweb-dev/web/blob/master/packages/test-runner-core/src/cli/terminal/DynamicTerminal.ts#L133

This means that in non-interactive scenarios like CI, the output will have ansi codes embedded in it with no way to disable it (without drastic measures like monkey patching process.stdout.write) that i can find.

MSLaguana avatar Jan 25 '24 00:01 MSLaguana