pick up instance variables from the class
Crude first set to creating types
This commit is contained in:
@ -6,6 +6,7 @@ module Melon
|
||||
def setup
|
||||
Register.machine.boot unless Register.machine.booted
|
||||
end
|
||||
|
||||
def test_creates_class_without_deriviation
|
||||
Compiler.compile "class Testing ; end"
|
||||
assert t = Parfait::Space.object_space.get_class_by_name(:Testing) , "No classes created"
|
||||
@ -18,5 +19,11 @@ module Melon
|
||||
assert_equal :List , t.super_class_name
|
||||
end
|
||||
|
||||
def test_picks_up_an_ivar_name
|
||||
Compiler.compile "class TestIvar < Object ; def meth; return @ivar;end; end"
|
||||
itest = Parfait::Space.object_space.get_class_by_name(:TestIvar)
|
||||
assert itest.instance_names.include?(:ivar) , itest.instance_names.inspect
|
||||
end
|
||||
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user