2018-04-26 11:31:37 +02:00
|
|
|
require_relative "../helper"
|
|
|
|
|
|
|
|
module Parfait
|
|
|
|
class ParfaitTest < MiniTest::Test
|
|
|
|
|
|
|
|
def setup
|
2018-06-29 23:39:23 +02:00
|
|
|
Parfait.boot!
|
2018-04-26 11:31:37 +02:00
|
|
|
@space = Parfait.object_space
|
|
|
|
end
|
2018-07-07 14:50:43 +02:00
|
|
|
def make_method
|
2018-07-13 20:50:40 +02:00
|
|
|
@obj = Parfait.object_space.get_type_by_class_name(:Object)
|
2018-07-07 14:50:43 +02:00
|
|
|
@args = Parfait::Type.for_hash( @obj.object_class , { bar: :Integer , foo: :Type})
|
|
|
|
@frame = Parfait::Type.for_hash( @obj.object_class , { local_bar: :Integer , local_foo: :Type})
|
2018-07-30 09:21:43 +02:00
|
|
|
@method = Parfait::CallableMethod.new( :meth , @obj , @args , @frame)
|
2018-07-07 14:50:43 +02:00
|
|
|
end
|
2018-04-26 11:31:37 +02:00
|
|
|
end
|
|
|
|
end
|