[前][次][番号順一覧][スレッド一覧]

ruby-changes:64527

From: Nobuyoshi <ko1@a...>
Date: Thu, 24 Dec 2020 01:40:22 +0900 (JST)
Subject: [ruby-changes:64527] fb54574393 (master): Pass keyword options in assert_syntax_error

https://git.ruby-lang.org/ruby.git/commit/?id=fb54574393

From fb545743932a5efd5a34ed9da981248dae3cc5ff Mon Sep 17 00:00:00 2001
From: Nobuyoshi Nakada <nobu@r...>
Date: Thu, 24 Dec 2020 01:24:30 +0900
Subject: Pass keyword options in assert_syntax_error


diff --git a/tool/lib/test/unit/assertions.rb b/tool/lib/test/unit/assertions.rb
index e740b17..14442c0 100644
--- a/tool/lib/test/unit/assertions.rb
+++ b/tool/lib/test/unit/assertions.rb
@@ -238,8 +238,8 @@ EOT https://github.com/ruby/ruby/blob/trunk/tool/lib/test/unit/assertions.rb#L238
       # compatibility with test-unit
       alias pend skip
 
-      def assert_syntax_error(code, error, *args)
-        prepare_syntax_check(code, *args) do |src, fname, line, mesg|
+      def assert_syntax_error(code, error, *args, **opt)
+        prepare_syntax_check(code, *args, **opt) do |src, fname, line, mesg|
           yield if defined?(yield)
           e = assert_raise(SyntaxError, mesg) do
             syntax_check(src, fname, line)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]