Fixed rcov exclude options.
[arvados.git] / tasks / spec.rake
index 4f3789b6ab1f882b85d8c1909b0d63c68fc6e508..b83d31692293121a189b1c03f6bbc4c0e36e01d0 100644 (file)
@@ -6,8 +6,10 @@ namespace :spec do
     t.spec_opts = ['--require', 'rubygems', '--color', '--format', 'specdoc']
     if RCOV_ENABLED
       if `which rcov`.strip == ""
-        STDERR.puts "Please install rcov:"
-        STDERR.puts "sudo gem install relevance-rcov"
+        STDERR.puts(
+          "Please install rcov and ensure that its binary is in the PATH:"
+        )
+        STDERR.puts("sudo gem install rcov")
         exit(1)
       end
       t.rcov = true
@@ -15,9 +17,13 @@ namespace :spec do
       t.rcov = false
     end
     t.rcov_opts = [
+      '--exclude', 'lib\\/compat',
       '--exclude', 'spec',
+      '--exclude', '\\.rvm\\/gems',
       '--exclude', '1\\.8\\/gems',
-      '--exclude', '1\\.9\\/gems'
+      '--exclude', '1\\.9\\/gems',
+      '--exclude', '\\.rvm',
+      '--exclude', '\\/Library\\/Ruby',
     ]
   end