Simple_cov: how to include engine tests in a report?

Our rail application uses an engine and relies on customer designs. The engine itself is not executable as a standalone program. Using simple_cov is great for customer projects. However, running all the tests (client and engine) causes the rake to be interrupted after all of them have been completed and a coverage report has been written for the client project. Mostly everything works, but writing a coverage report for the engine.

The engine is stored in an external folder next to the client project. Test suite used - rspec

So, is there a way to include the engine in the SimpleCov configuration?

+4
source share
1 answer

Where do you need simple characters? I had a similar problem, not with the engine, but rather tried to cover all the tests in a "non-standard" rails application with a service architecture. Most files (even files in lib / and models /) were not loaded. The way I decided is to require simple_cov in "config / environment / test.rb". Hope this helps!

0
source

Source: https://habr.com/ru/post/1447919/


All Articles