rubyx/test/elf/test_hello.rb
Torsten Ruger 8dbbffd58e fix tests for NameExpression split
also necessitates giving method name without the wrapping expression
which is simpler anyway
2017-01-16 09:34:47 +02:00

21 lines
509 B
Ruby

require_relative "../helper"
class HelloTest < MiniTest::Test
include AST::Sexp
def check
machine = Register.machine.boot
Vm.compile_ast( @input )
objects = Register::Collector.collect_space
machine.translate_arm
writer = Elf::ObjectWriter.new(machine , objects )
writer.save "test/hello.o"
end
def test_string_put
@input = s(:statements, s(:return, s(:call, :putstring, s(:arguments),
s(:receiver, s(:string, "Hello again\\n")))))
check
end
end