I am trying to configure a rails project to jenkins. there are some test code. I am covering the test code using rcov. But when i build the project on jenkins , the following error was found.
Publishing rcov report...
rcov report index file wasn't found
In post build action i made the necessary steps. default directory for "Rcov report directory" is coverage/rcov
any solution ?
You should follow the bellow step to get success:
jenkins_app/configure/
Then you need to go Post-build Actions
and then go Publish Rcov report
You will see Rcov report directory
text field and then fill the text box value by coverage/rcov
Also before do this you need to ensure that you have right gem in your gem file:
#Gemfile
gem 'simplecov', :require => false, :group => :test
gem 'simplecov-rcov'
And also configure your spec/spec_helper.rb
like this:
require 'simplecov'
require 'simplecov-rcov'
SimpleCov.formatter = SimpleCov::Formatter::RcovFormatter
SimpleCov.start 'rails'
I hope then your issue will be fixed!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With