summaryrefslogtreecommitdiff
path: root/test/ruby
diff options
context:
space:
mode:
authorKoichi Sasada <ko1@atdot.net>2024-04-17 17:40:20 +0900
committerKoichi Sasada <ko1@atdot.net>2024-04-17 17:40:20 +0900
commit7bc66a366ded3ae2d07a418e17a9da6ee24612fd (patch)
tree4dbeb9a63b1f3f78fbed549b2d3e8c98d2e3445d /test/ruby
parenteac3dee9cdefcc414af832c99a95383a38790d1c (diff)
skip on Prism generated iseq
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_iseq.rb10
1 files changed, 8 insertions, 2 deletions
diff --git a/test/ruby/test_iseq.rb b/test/ruby/test_iseq.rb
index a31605885a..dbf91fe8c9 100644
--- a/test/ruby/test_iseq.rb
+++ b/test/ruby/test_iseq.rb
@@ -835,8 +835,14 @@ class TestISeq < Test::Unit::TestCase
end
def test_unused_param
- assert_equal true, RubyVM::InstructionSequence.of(method(:block_using_method)).to_a.dig(11, :use_block)
- assert_equal nil, RubyVM::InstructionSequence.of(method(:block_unused_method)).to_a.dig(11, :use_block)
+ a = RubyVM::InstructionSequence.of(method(:block_using_method)).to_a
+
+ omit 'TODO: Prism' if a.dig(4, :parser) != :"parse.y"
+
+ assert_equal true, a.dig(11, :use_block)
+
+ b = RubyVM::InstructionSequence.of(method(:block_unused_method)).to_a
+ assert_equal nil, b.dig(11, :use_block)
end
def test_compile_prism_with_invalid_object_type