relevance/rcov — Issue #89: RCov fails detecting coverage of RSpec 2
Author: torbjoernk
Created: 2012-01-17 15:38:12+00:00
State: open

This issue is maybe somehow related to [Issue #88](https://github.com/relevance/rcov/issues/88).

Running this Rake task should generate the coverage report of my specs for RSpec:

desc "Run RCov to get coverage of Specs"
Rcov::RcovTask.new(:rcov_spec) do |t|
# require 'rspec'
t.pattern = 'spec/**/*_spec.rb'
t.verbose = true
t.rcov_opts << "--html"
t.rcov_opts << "--text-summary"
t.output_dir = "coverage/spec"
end

The report is generated, but somehow none of method bodies of my tested files in lib/**/* is marked as covered. ([compare screenshot](http://www.flickr.com/photos/58595396@N02/6714759947/) ). Only `require`, class definitions (`class Xyz`) and method definitions (`def method_name`) are marked as covered, though I'm 100% sure, some methods (not all) are being tested.

---
ruby 1.8.7 (2011-02-18 patchlevel 334) [x86_64-linux]
rspec 2.8.0
rcov 0.9.11 2010-02-28
rake 0.9.2