Enable raw mode for testing UI output
6.xWhen testing CLI commands, instantiate cliui with { raw: true }. This mode collects log messages in memory and disables color transformations (ANSI sequences), making it easy to assert against expected output.
To retrieve logs, use ui.logger.getRenderer().getLogs().
const ui = cliui({ raw: true })
ui.logger.info('This is an info message')
const logs = ui.logger.getRenderer().getLogs()
// logs will contain the raw message without ANSI colors
// e.g., [{ stream: 'stdout', message: '[ cyan(info) ] This is an info message' }]