Skip to content

Commit f2f0307

Browse files
author
rli9
committed
fix issue 204 by escape special characters in root path such as '(', ')'
1 parent a3387f7 commit f2f0307

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/simplecov/defaults.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
SimpleCov.profiles.define 'root_filter' do
55
# Exclude all files outside of simplecov root
66
add_filter do |src|
7-
!(src.filename =~ /^#{SimpleCov.root}/)
7+
!(src.filename =~ /^#{Regexp.escape(SimpleCov.root)}/)
88
end
99
end
1010

0 commit comments

Comments
 (0)