rubyx/test/fragments/test_foo.rb

30 lines
411 B
Ruby
Raw Normal View History

2014-05-21 20:37:04 +02:00
require_relative 'helper'
class TestFoo < MiniTest::Test
include Fragments
def test_foo2
2014-05-21 20:37:04 +02:00
@string_input = <<HERE
2015-07-18 14:28:57 +02:00
def foo2(x)
a = 5
end
2014-06-07 22:22:32 +02:00
3.foo( 4 )
2014-05-21 20:37:04 +02:00
HERE
2015-07-19 11:33:33 +02:00
@expect = [ Virtual::Return ]
check
2014-05-21 20:37:04 +02:00
end
def test_foo
2015-08-20 16:06:44 +02:00
@string_input = "3.foo( 4 )"
@expect = [Virtual::Return ]
check
end
def test_add
@string_input = "2 + 5"
@expect = [Virtual::Return ]
check
end
end