зеркало из https://github.com/github/ruby.git
* bootstraptest/runner.rb (assert_not_match): new method.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13637 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
4005af4520
Коммит
ef1d280a4c
|
@ -1,3 +1,7 @@
|
|||
Fri Oct 5 16:42:27 2007 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* bootstraptest/runner.rb (assert_not_match): new method.
|
||||
|
||||
Fri Oct 5 16:15:52 2007 Akinori MUSHA <knu@iDaemons.org>
|
||||
|
||||
* configure.in: Turn on --enable-pthread by default for FreeBSD
|
||||
|
|
|
@ -166,6 +166,18 @@ def assert_match(expected_pattern, testsrc, message = '')
|
|||
}
|
||||
end
|
||||
|
||||
def assert_not_match(unexpected_pattern, testsrc, message = '')
|
||||
newtest
|
||||
assert_check(testsrc, message) {|result|
|
||||
if unexpected_pattern !~ result
|
||||
nil
|
||||
else
|
||||
desc = "#{unexpected_pattern.inspect} expected to be !~\n#{result.inspect}"
|
||||
pretty(testsrc, desc, result)
|
||||
end
|
||||
}
|
||||
end
|
||||
|
||||
def assert_normal_exit(testsrc, message = '')
|
||||
newtest
|
||||
$stderr.puts "\##{@count} #{@location}" if @verbose
|
||||
|
|
|
@ -21,3 +21,8 @@ assert_normal_exit %q{
|
|||
require 'continuation'
|
||||
Fiber.new{ callcc{|c| @c = c } }.resume
|
||||
}, '[ruby-dev:31913]'
|
||||
|
||||
assert_not_match /method_missing/, %q{
|
||||
STDERR.reopen(STDOUT)
|
||||
variable_or_mehtod_not_exist
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче