From f38aad8d878e5fbf760bf6ec71825a41d24e082e Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 4 Feb 2011 18:34:12 +0000 Subject: [PATCH] * test/fileutils/fileasserts.rb (Test::Unit::Assertions#assert_block): show the given message. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30785 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ test/fileutils/fileasserts.rb | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/ChangeLog b/ChangeLog index 0f8b00207d..b01e63bf7d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sat Feb 5 03:34:02 2011 Nobuyoshi Nakada + + * test/fileutils/fileasserts.rb (Test::Unit::Assertions#assert_block): + show the given message. + Sat Feb 5 02:09:39 2011 Nobuyoshi Nakada * parse.y (lex_getline, parser_set_encode): set encoding of lines diff --git a/test/fileutils/fileasserts.rb b/test/fileutils/fileasserts.rb index bad87e9ce0..579fefd15e 100644 --- a/test/fileutils/fileasserts.rb +++ b/test/fileutils/fileasserts.rb @@ -8,6 +8,10 @@ module Test yield end + def assert_block msg = nil + assert yield, msg + end + def assert_same_file(from, to) _wrap_assertion { assert_block("file #{from} != #{to}") {