Geminstaller C0 Coverage Information - RCov

/Users/woolley/.rvm/gems/ruby-1.8.7-p174@geminstaller/gems/rspec-1.3.0/lib/spec/matchers/has.rb

Name Total Lines Lines of Code Total Coverage Code Coverage
/Users/woolley/.rvm/gems/ruby-1.8.7-p174@geminstaller/gems/rspec-1.3.0/lib/spec/matchers/has.rb 35 25
51.43%
40.00%

Key

Code reported as executed by Ruby looks like this...and this: this line is also marked as covered.Lines considered as run by rcov, but not reported by Ruby, look like this,and this: these lines were inferred by rcov (using simple heuristics).Finally, here's a line marked as not executed.

Coverage Details

1 module Spec
2   module Matchers
3     
4     class Has
5       
6       def initialize(expected, *args, &block)
7         @expected, @args, @block = expected, args, block
8       end
9       
10       def matches?(actual)
11         actual.__send__(predicate(@expected), *@args, &@block)
12       end
13       
14       def failure_message_for_should
15         "expected ##{predicate(@expected)}(#{@args[0].inspect}) to return true, got false"
16       end
17       
18       def failure_message_for_should_not
19         "expected ##{predicate(@expected)}(#{@args[0].inspect}) to return false, got true"
20       end
21       
22       def description
23         "have key #{@args[0].inspect}"
24       end
25     
26     private
27     
28       def predicate(sym)
29         "#{sym.to_s.sub("have_","has_")}?".to_sym
30       end
31       
32     end
33     
34   end
35 end

Generated on Mon May 10 23:40:27 -0700 2010 with rcov 0.9.8