dariodf / lcov_ex

Elixir lcov report generator
MIT License
31 stars 7 forks source link

Run with --quiet as a test coverage tool? #19

Open grantwest opened 1 year ago

grantwest commented 1 year ago

Is there a way to run without output when using LcovEx as test coverage tool?

dariodf commented 1 year ago

Sorry about the late response. The --quiet option actually just changes the Mix shell to the Mix.Shell.Quiet one for the mix lcov task:

https://github.com/dariodf/lcov_ex/blob/aae60320e471d685b36cc7c763a697c43df17842/lib/tasks/lcov.ex#L19

I'm guessing you could try running that configuration in an alias or test_helper.exs, although it would probably just block the whole test process output. Don't know if that's useful for you, or which specific part you wanted to be silent.

grantwest commented 1 year ago

I am running mix test.watch --cover, and the extra output from lcov displaces my tests failures by a few lines on the terminal: Screenshot 2023-06-03 at 9 50 50 AM

It's a small thing, but since those lcov output lines aren't providing me any value in this situation, I would prefer to just have more of the test output visible without having to scroll.

I have this combined with the vscode Coverage Gutters extension to see realtime coverage in my IDE.