MiniTest::Unit::TestCase
# File test/test_unified_ruby.rb, line 26 26: def test_pre_call 27: u = PreUnifier.new 28: 29: input = [:call, [:self], :method] 30: expect = s(:call, s(:self), :method, s(:arglist)) 31: 32: assert_equal expect, u.process(input) 33: 34: input = [:fcall, :m, [:array, [:lit, 42]]] 35: expect = s(:fcall, :m, s(:arglist, s(:lit, 42))) 36: 37: assert_equal expect, u.process(input) 38: end
# File test/test_unified_ruby.rb, line 12 12: def test_pre_fcall 13: u = PreUnifier.new 14: 15: input = [:fcall, :block_given?] 16: expect = s(:fcall, :block_given?, s(:arglist)) 17: 18: assert_equal expect, u.process(input) 19: 20: input = [:fcall, :m, [:array, [:lit, 42]]] 21: expect = s(:fcall, :m, s(:arglist, s(:lit, 42))) 22: 23: assert_equal expect, u.process(input) 24: end
# File test/test_unified_ruby.rb, line 40 40: def test_process_bmethod 41: u = Unifier.new 42: 43: raw = [:defn, :myproc3, 44: [:bmethod, 45: [:masgn, [:array, 46: [:dasgn_curr, :a], 47: [:dasgn_curr, :b], 48: [:dasgn_curr, :c]], 49: nil, nil]]] 50: 51: s = s(:defn, :myproc3, 52: s(:args, :a, :b, :c), 53: s(:scope, s(:block))) 54: 55: assert_equal s, u.process(raw) 56: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.