1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* lib/test/unit/assertions.rb (assert_no_match): don't count up as two

assertions.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@21376 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
akr 2009-01-07 15:33:17 +00:00
parent 3802c43ea1
commit d45c4a8107
2 changed files with 6 additions and 0 deletions

View file

@ -1,3 +1,8 @@
Thu Jan 8 00:31:58 2009 Tanaka Akira <akr@fsij.org>
* lib/test/unit/assertions.rb (assert_no_match): don't count up as two
assertions.
Thu Jan 8 00:26:35 2009 Tanaka Akira <akr@fsij.org>
* ext/socket/socket.c (addrinfo_getnameinfo): use NI_DGRAM if socktype

View file

@ -92,6 +92,7 @@ module Test
def assert_no_match(regexp, string, msg=nil)
assert_instance_of(Regexp, regexp, "The first argument to assert_no_match should be a Regexp.")
self._assertions -= 1
msg = message(msg) { "<#{mu_pp(regexp)}> expected to not match\n<#{mu_pp(string)}>" }
assert(regexp !~ string, msg)
end