# File test/unit/assertions.rb, line 136 def assert_match(regexp, string, message="") _wrap_assertion { assert_instance_of(Regexp, regexp, "The first argument to assert_match should be a Regexp.") full_message = build_message(message, string, regexp.source) { | arg1, arg2 | "Expected <#{arg1}> to match regexp </#{arg2}/>" } assert_block(full_message) { regexp =~ string } } end