violet_rails icon indicating copy to clipboard operation
violet_rails copied to clipboard

enforce minimum code coverage requirement before merging to master

Open donrestarone opened this issue 3 years ago • 3 comments

calculate current test coverage after we fix: https://github.com/restarone/violet_rails/issues/245

and then add a rule that prevents merging to master if the change lowers coverage

donrestarone avatar May 30 '22 13:05 donrestarone

to see test coverage report please run:

./clean_run_tests.sh

and then you will see

open coverage/index.html
Screen Shot 2022-06-15 at 3 09 10 PM

donrestarone avatar Jun 15 '22 19:06 donrestarone

CI example: https://github.com/restarone/violet_rails/blob/master/.github/workflows/ruby.yml

donrestarone avatar Jun 15 '22 19:06 donrestarone

if test coverage is lower with the change applied, we should fail

donrestarone avatar Jun 15 '22 19:06 donrestarone