Skip to content

Commit 7824b2d

Browse files
committed
[GR-32856] Fix --cpusampler test
* #itself does not execute the block, #yield_self and #then do.
1 parent 587e3e7 commit 7824b2d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spec/truffle/tools_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@
5959
code = <<~RUBY
6060
def foo
6161
n = 0
62-
loop { itself { n += 1 } }
62+
loop { yield_self { n += 1 } }
6363
n
6464
end
6565
t = Thread.new { foo }
@@ -70,7 +70,7 @@ def foo
7070
RUBY
7171
out = ruby_exe(code, options: "--cpusampler")
7272
out.should.include?(":kill")
73-
out.should.include?("block in Object#foo")
73+
out.should.include?("block (2 levels) in Object#foo")
7474
out.should_not.include?('KillException')
7575
$?.should.success?
7676
end

0 commit comments

Comments
 (0)