This commit is contained in:
Torsten Ruger 2015-07-19 12:33:33 +03:00
parent 1f95d8994c
commit 6da1c69b87
3 changed files with 3 additions and 2 deletions

View File

@ -9,6 +9,7 @@ module Fragments
def check
expressions = Virtual.machine.boot.compile_main @string_input
@expect.each_with_index do | should , i |
assert expressions[i].is_a?(Virtual::Slot) , "compiles should return slots, not #{should.class}"
assert_equal should , expressions[i].class
end
# Virtual.machine.run_passes

View File

@ -10,7 +10,7 @@ def foo2(x)
end
3.foo( 4 )
HERE
@expect = [Parfait::Method , Virtual::Return ]
@expect = [ Virtual::Return ]
check
end

View File

@ -6,7 +6,7 @@ class TestFunctions < MiniTest::Test
def test_functions
@string_input = <<HERE
def minus(a,b)
a - b
a - b
end
def plus(a, b)
a + b