pass return integer back out through exit
for testing of binaries later (and off course general correctness) Some tests were using the fact that the interpreter was used, changed those to return ints rather than strings
This commit is contained in:
@ -13,9 +13,9 @@ module Risc
|
||||
#show_main_ticks # get output of what is
|
||||
check_main_chain [LoadConstant, SlotToReg, RegToSlot, SlotToReg, SlotToReg,
|
||||
RegToSlot, SlotToReg, SlotToReg, RegToSlot, SlotToReg,
|
||||
SlotToReg, SlotToReg, FunctionReturn, Transfer, Syscall,
|
||||
NilClass]
|
||||
assert_equal 15 , get_return.value
|
||||
SlotToReg, SlotToReg, FunctionReturn, SlotToReg, SlotToReg,
|
||||
Branch, Transfer, Syscall, NilClass]
|
||||
assert_equal 15 , get_return
|
||||
end
|
||||
|
||||
def test_call_main
|
||||
@ -36,11 +36,11 @@ module Risc
|
||||
assert_equal Fixnum , link.class
|
||||
end
|
||||
def test_transfer
|
||||
transfer = main_ticks(14)
|
||||
transfer = main_ticks(17)
|
||||
assert_equal Transfer , transfer.class
|
||||
end
|
||||
def test_sys
|
||||
sys = main_ticks(15)
|
||||
sys = main_ticks(18)
|
||||
assert_equal Syscall , sys.class
|
||||
end
|
||||
end
|
||||
|
Reference in New Issue
Block a user