开发者

Aggregate cover_me results for rspec and cucumber

Before moving over to ruby 1.9.2 and cover_me I was using rcov. We don't tend to unit test controllers, relying instead on cucumb开发者_如何学JAVAer coverage. With rcov it was possible to aggregate the coverage results from both the cucumber and rspec runs. Is this possible with cover_me?


Here's the Rakefile that I ended up with, you can get coverage for rspec, cucumber or both combined:

namespace :cover_me do
  task :report do
    require 'cover_me'
    CoverMe.complete!
  end

  task :all => %w{ rake:spec rake:cucumber report }
  task :spec => %w{ rake:spec report }
  task :cucumber => %w{ rake:cucumber report }
end
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜