Open jar349 opened 8 months ago
I suspect that this may be due to this:
note:
Line coverage (27.16%) is below the expected minimum coverage (100.00%).
SimpleCov failed with exit 2 due to a coverage related error
The problem I have is that SimpleCov is configured in ./specs/spec_helper.rb
to require full coverage:
SimpleCov.minimum_coverage 100
But with ruby-lsp-rspec, there doesn't seem to be a way to just run all tests? The code lenses are contextual in a single file. I need a way to run all tests so that my coverage will be at 100% and rspec will exit with code zero.
So the problem I have with only being able to run the tests from a code lens is that I don't have a way to run ALL the tests in my repo at once, which means my coverage metrics will always fail my tests.
Would it be possible to add a way to run all the tests in a repo?
Is there a way to provide an ENV for the CodeLens to include in the test invocation? Then you could gate the simplecov config with something like ENV['SIMPLECOV_DISABLED'] == true
. Right now I've just done that via .env file that differs from my CI one, but it'd be cleaner if its something I could configure for the VS Code workspace instead.
In a terminal, running:
bundle exec rspec
runs all my tests in./spec
and they all pass.In the Testing pane of VS Code, I run some tests and they pass but appear visibly to have failed. See the image below and note the
1 example, 0 failures
I have this in the
development
group of myGemfile
: