From 27df1a84bc5310bcd32d90b7157a3ad46ef3ac76 Mon Sep 17 00:00:00 2001 From: "Yukihiro \"Matz\" Matsumoto" Date: Wed, 14 May 2014 17:38:27 +0900 Subject: Kernel.local_variables to list UPVAR as well --- mrbgems/mruby-proc-ext/test/proc.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'mrbgems/mruby-proc-ext/test') diff --git a/mrbgems/mruby-proc-ext/test/proc.rb b/mrbgems/mruby-proc-ext/test/proc.rb index a5611e586..4da98de05 100644 --- a/mrbgems/mruby-proc-ext/test/proc.rb +++ b/mrbgems/mruby-proc-ext/test/proc.rb @@ -81,4 +81,10 @@ assert('Kernel.local_variables') do vars = Kernel.local_variables.sort assert_equal [:a, :b, :vars], vars + + proc { + c = 2 + vars = Kernel.local_variables.sort + assert_equal [:a, :b, :c, :vars], vars + }.call end -- cgit v1.2.3