Move Array#map to Ruby

Co-Authored-By: Aaron Patterson <tenderlove@ruby-lang.org>
This commit is contained in:
Takashi Kokubun 2024-11-12 20:47:48 -08:00
parent c9a5a71695
commit 01db456196
Notes: git 2024-11-13 20:27:44 +00:00
6 changed files with 43 additions and 12 deletions

View file

@ -26,11 +26,14 @@ class TestDebug < Test::Unit::TestCase
count[:iseq] += 1
assert_instance_of(RubyVM::InstructionSequence, iseq, msg)
# check same location
assert_equal(loc.path, iseq.path, msg)
assert_equal(loc.absolute_path, iseq.absolute_path, msg)
#assert_equal(loc.label, iseq.label, msg)
assert_operator(loc.lineno, :>=, iseq.first_lineno, msg)
# Backtraces and source locations don't match for :c_trace methods
unless iseq.disasm.include?('C_TRACE')
# check same location
assert_equal(loc.path, iseq.path, msg)
assert_equal(loc.absolute_path, iseq.absolute_path, msg)
#assert_equal(loc.label, iseq.label, msg)
assert_operator(loc.lineno, :>=, iseq.first_lineno, msg)
end
end
assert_instance_of(Thread::Backtrace::Location, loc, msg)