simple mom test for simple call

This commit is contained in:
Torsten Ruger 2018-03-12 18:16:23 +05:30
parent c806106917
commit 45bfe118d1
2 changed files with 24 additions and 1 deletions

View File

@ -1,7 +1,7 @@
require_relative "helper"
module Mom
class TestCall < MiniTest::Test
class TestDynamicCall < MiniTest::Test
include MomCompile
def setup

View File

@ -0,0 +1,23 @@
require_relative "helper"
module Mom
class TestSimpleCall < MiniTest::Test
include MomCompile
def setup
Risc.machine.boot
@stats = compile_first_method_flat( "5.mod4")
@first = @stats.next
end
def test_if_compiles
assert_equal @stats.last.class , SimpleCall , @stats
end
def test_length
assert_equal 3 , @stats.length
end
def test_array
check_array [MessageSetup,ArgumentTransfer,SimpleCall] , @stats
end
end
end