more and better tests

especially vool
This commit is contained in:
2019-08-08 12:18:36 +03:00
parent d5625a70d7
commit 82c9f1d97f
10 changed files with 109 additions and 53 deletions

View File

@ -12,9 +12,6 @@ module Risc
vool.to_mom(nil)
vool
end
def in_test_mom(str)
FIXMERubyX::RubyXCompiler.new(in_Test(str)).ruby_to_mom()
end
def create_method(body = "@ivar = 5")
in_test_vool("def meth; #{body};end")
test = Parfait.object_space.get_class_by_name(:Test)
@ -65,9 +62,9 @@ module Risc
end
def constant_setup(input)
mom = RubyX::RubyXCompiler.new(RubyX.default_test_options).ruby_to_mom(in_Test(input))
assert_equal Mom::MomCompiler , mom.class
assert_equal Mom::MomCollection , mom.class
compiler = mom.method_compilers.first
assert_equal MethodCompiler , compiler.class
assert_equal Mom::MethodCompiler , compiler.class
compiler
end
def test_has_method_constant