Sha256: 431dbb1a5d22da0415f780469705599cc3ecfbb0e0f011e8a4b6821c5f9a53f3
Contents?: true
Size: 1.3 KB
Versions: 11
Compression:
Stored size: 1.3 KB
Contents
#!/usr/bin/env ruby require 'test/unit' # require 'ruby-debug'; Debugger.start # Test info variables command class TestInfoVar < Test::Unit::TestCase @@SRC_DIR = File.join(Dir.pwd, File.dirname(__FILE__)) unless defined?(@@SRC_DIR) require File.join(@@SRC_DIR, 'helper') include TestHelper def test_info_variables Dir.chdir(@@SRC_DIR) do filter = Proc.new{|got_lines, correct_lines| [got_lines[13-1], correct_lines[13-1]].each do |s| s.sub!(/Mine:0x[0-9,a-f]+/, 'Mine:') end [got_lines, correct_lines].each do |a| a.each do |s| s.sub!(/Lousy_inspect:0x[0-9,a-f]+/, 'Lousy_inspect:') s.sub!(/UnsuspectingClass:0x[0-9,a-f]+/, 'UnsuspectingClass:') end end } testname='info-var' script = File.join('data', testname + '.cmd') assert_equal(true, run_debugger(testname, "--script #{script} -- ./info-var-bug.rb", nil, filter)) testname='info-var-bug2' script = File.join('data', testname + '.cmd') assert_equal(true, run_debugger(testname, "--script #{script} -- ./info-var-bug2.rb", nil)) end end end
Version data entries
11 entries across 11 versions & 1 rubygems