simple mom test for simple call
This commit is contained in:
parent
c806106917
commit
45bfe118d1
@ -1,7 +1,7 @@
|
|||||||
require_relative "helper"
|
require_relative "helper"
|
||||||
|
|
||||||
module Mom
|
module Mom
|
||||||
class TestCall < MiniTest::Test
|
class TestDynamicCall < MiniTest::Test
|
||||||
include MomCompile
|
include MomCompile
|
||||||
|
|
||||||
def setup
|
def setup
|
||||||
|
23
test/mom/test_simple_call_statement.rb
Normal file
23
test/mom/test_simple_call_statement.rb
Normal 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
|
Loading…
x
Reference in New Issue
Block a user