Commit 20c6810e authored by Jun Hiroe's avatar Jun Hiroe

I fix order of actual and expect test value in proc.rb.

parent 6583f340
...@@ -2,11 +2,11 @@ ...@@ -2,11 +2,11 @@
# Proc ISO Test # Proc ISO Test
assert('Proc', '15.2.17') do assert('Proc', '15.2.17') do
assert_equal Proc.class, Class assert_equal Class, Proc.class
end end
assert('Proc superclass', '15.2.17.2') do assert('Proc superclass', '15.2.17.2') do
assert_equal Proc.superclass, Object assert_equal Object, Proc.superclass
end end
assert('Proc.new', '15.2.17.3.1') do assert('Proc.new', '15.2.17.3.1') do
...@@ -36,10 +36,10 @@ assert('Proc#arity', '15.2.17.4.2') do ...@@ -36,10 +36,10 @@ assert('Proc#arity', '15.2.17.4.2') do
c = Proc.new {|x=0, y|}.arity c = Proc.new {|x=0, y|}.arity
d = Proc.new {|(x, y), z=0|}.arity d = Proc.new {|(x, y), z=0|}.arity
assert_equal a, 2 assert_equal 2, a
assert_equal b, -3 assert_equal(-3, b)
assert_equal c, 1 assert_equal 1, c
assert_equal d, 1 assert_equal 1, d
end end
assert('Proc#call', '15.2.17.4.3') do assert('Proc#call', '15.2.17.4.3') do
...@@ -51,6 +51,6 @@ assert('Proc#call', '15.2.17.4.3') do ...@@ -51,6 +51,6 @@ assert('Proc#call', '15.2.17.4.3') do
b2 = Proc.new { |i| a2 += i } b2 = Proc.new { |i| a2 += i }
b2.call(5) b2.call(5)
assert_equal a, 1 assert_equal 1, a
assert_equal a2, 5 assert_equal 5, a2
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment