Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove ansi sequence from luassert output #24

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

MeanderingProgrammer
Copy link

Details

When running in a TTY luassert defaults to adding ansi colors when showning table differences for a failed test:
https://github.com/nvim-lua/plenary.nvim/blob/master/lua/luassert/formatters/init.lua#L255

When looking at these through the neotest panel everything looks great. However diagnostics do not appear to have any ansi parsing and instead print out the raw sequence.

The parameter that defines the color can be modified and effectively disabled by setting it to "none".

Before After
current-ansii after-parameter

This isn't a big deal and I can set it up per project. Also if I'm missing another way of handling this definitely LMK. As is this disables colors for both diagnostics as well as in the neotest panel.

## Details

When running in a TTY luassert defaults to adding ansi colors when
showning table differences for a failed test:
https://github.com/nvim-lua/plenary.nvim/blob/master/lua/luassert/formatters/init.lua#L255

When looking at these through the `neotest` panel everything looks
great. However diagnostics do not appear to have any ansi parsing and
instead print out the raw sequence.

The parameter that defines the color can be modified and effectively
disabled by setting it to "none".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant