summaryrefslogtreecommitdiff
path: root/lib/test/unit/assertions.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/test/unit/assertions.rb')
-rw-r--r--lib/test/unit/assertions.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/test/unit/assertions.rb b/lib/test/unit/assertions.rb
index 49987fab57..39a3c85600 100644
--- a/lib/test/unit/assertions.rb
+++ b/lib/test/unit/assertions.rb
@@ -317,7 +317,7 @@ EOT
def build_message(head, template=nil, *arguments) #:nodoc:
template &&= template.chomp
- template.gsub(/\?/) { mu_pp(arguments.shift) }
+ template.gsub(/\G((?:[^\\]|\\.)*?)(\\)?\?/) { $1 + ($2 ? "?" : mu_pp(arguments.shift)) }
end
end
end