2019-09-17 09:16:59 +02:00
|
|
|
require_relative "helper"
|
|
|
|
|
2019-10-03 19:55:41 +02:00
|
|
|
module SlotMachine
|
|
|
|
class TestJump < SlotMachineInstructionTest
|
2019-09-17 09:16:59 +02:00
|
|
|
def instruction
|
|
|
|
Jump.new( Label.new("ok" , "target"))
|
|
|
|
end
|
|
|
|
def test_len
|
|
|
|
assert_equal 2 , all.length , all_str
|
|
|
|
end
|
|
|
|
def test_1_slot
|
|
|
|
assert_branch risc(1) , "target"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|