Sha256: 9a8efa23948c2b67930bfa58de75f78ac5db7c478e8978bae8dc4534749451c5
Contents?: true
Size: 373 Bytes
Versions: 26
Compression:
Stored size: 373 Bytes
Contents
module Mocha class BacktraceFilter LIB_DIRECTORY = File.expand_path(File.join(File.dirname(__FILE__), '..')) + File::SEPARATOR def initialize(lib_directory = LIB_DIRECTORY) @path_pattern = Regexp.new(lib_directory) end def filtered(backtrace) backtrace.reject { |location| @path_pattern.match(File.expand_path(location)) } end end end
Version data entries
26 entries across 26 versions & 3 rubygems