Skip to content

Commit b9dc0a2

Browse files
etiennebarrietekknolagi
authored andcommitted
Add regression test for module prepend crash
1 parent a19beca commit b9dc0a2

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

test/ruby/test_yjit.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1850,6 +1850,19 @@ def test_yjit_dump_insns
18501850
assert_not_predicate(status, :signaled?)
18511851
end
18521852

1853+
def test_yjit_prelude_bundler_setup
1854+
Tempfile.create do |f|
1855+
f.write(<<~'GEMFILE')
1856+
source "https://rubygems.org"
1857+
module C
1858+
end
1859+
Kernel.prepend(C)
1860+
GEMFILE
1861+
f.flush
1862+
assert_separately([{ "BUNDLER_SETUP" => "bundler/setup", "BUNDLE_GEMFILE" => f.path }, "--enable=gems", "--yjit"], "")
1863+
end
1864+
end
1865+
18531866
private
18541867

18551868
def code_gc_helpers

0 commit comments

Comments
 (0)