fix coverage paths for new structure by #4123

This commit is contained in:
Colin Surprenant 2015-11-16 19:33:34 -05:00
parent 560dda251c
commit 2e80cd0cb7

View file

@ -5,20 +5,19 @@ module CoverageHelper
##
# Skip list used to avoid loading certain patterns within
# the logstash directories, this patterns are excluded becuause
# the logstash directories, this patterns are excluded because
# of potential problems or because they are going to be loaded
# in another way.
##
SKIP_LIST = Regexp.union([
/^lib\/bootstrap\/rspec.rb$/,
/^lib\/logstash\/util\/prctl.rb$/
/^logstash-core\/lib\/logstash\/util\/prctl.rb$/
])
def self.eager_load
Dir.glob("lib/**/*.rb") do |file|
Dir.glob("{logstash-core{/,-event/},}lib/**/*.rb") do |file|
next if file =~ SKIP_LIST
require file
end
end
end