summaryrefslogtreecommitdiff
path: root/test/irb/test_irb.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/irb/test_irb.rb')
-rw-r--r--test/irb/test_irb.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/test/irb/test_irb.rb b/test/irb/test_irb.rb
index e89f2a1c70..b32e857c1e 100644
--- a/test/irb/test_irb.rb
+++ b/test/irb/test_irb.rb
@@ -733,9 +733,13 @@ module TestIRB
private
+ def build_binding
+ Object.new.instance_eval { binding }
+ end
+
def build_irb
IRB.init_config(nil)
- workspace = IRB::WorkSpace.new(TOPLEVEL_BINDING.dup)
+ workspace = IRB::WorkSpace.new(build_binding)
IRB.conf[:VERBOSE] = false
IRB::Irb.new(workspace, TestInputMethod.new)