Skip to content

Commit

Permalink
Ignore files from RCov stats
Browse files Browse the repository at this point in the history
  • Loading branch information
lsegal committed Oct 16, 2009
1 parent 24462a6 commit 0d541b7
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,14 @@ Spec::Rake::SpecTask.new("specs") do |t|
t.spec_opts = ["--format", "specdoc", "--colour"]
t.spec_opts += ["--require", File.join(File.dirname(__FILE__), 'spec', 'spec_helper')]
t.spec_files = Dir["spec/**/*_spec.rb"].sort
t.rcov = true if ENV['RCOV']
t.rcov_opts = ['-x', '_spec\.rb$,spec_helper\.rb$']

if ENV['RCOV']
hide = '_spec\.rb$,spec_helper\.rb$,ruby_lex\.rb$,autoload\.rb$'
hide += ',legacy\/.+_handler' if RUBY19
hide += ',ruby_parser\.rb$,ast_node\.rb$,handlers\/ruby\/[^\/]+\.rb$' if RUBY18
t.rcov = true
t.rcov_opts = ['-x', hide]
end
end
task :spec => :specs

Expand Down

0 comments on commit 0d541b7

Please sign in to comment.