1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

Fix PryTester

This commit is contained in:
Conrad Irwin 2012-12-17 23:54:07 -08:00
parent 5da52a02ca
commit edd3970917

View file

@ -103,14 +103,11 @@ end
class PryTester class PryTester
attr_reader :pry, :out attr_reader :pry, :out
def initialize(context = TOPLEVEL_BINDING, options = {}) def initialize(target = TOPLEVEL_BINDING, options = {})
@pry = Pry.new(options) @pry = Pry.new(options.merge(:target => target))
@history = options[:history] @history = options[:history]
if context
self.context = context
@pry.inject_sticky_locals! @pry.inject_sticky_locals!
end
@pry.input_array << nil # TODO: shouldn't need this @pry.input_array << nil # TODO: shouldn't need this
reset_output reset_output