We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents e59da75 + 02a29dc commit e2578beCopy full SHA for e2578be
1 file changed
test/zlib/test_zlib.rb
@@ -9,6 +9,9 @@
9
begin
10
require 'zlib'
11
rescue LoadError
12
+else
13
+ z = "/zlib.#{RbConfig::CONFIG["DLEXT"]}"
14
+ LOADED_ZLIB, = $".select {|f| f.end_with?(z)}
15
end
16
17
if defined? Zlib
@@ -1525,7 +1528,7 @@ def test_gunzip_encoding
1525
1528
1526
1529
1527
1530
def test_gunzip_no_memory_leak
- assert_no_memory_leak(%[-rzlib], "#{<<~"{#"}", "#{<<~'};'}")
1531
+ assert_no_memory_leak(%W[-r#{LOADED_ZLIB}], "#{<<~"{#"}", "#{<<~'};'}")
1532
d = Zlib.gzip("data")
1533
{#
1534
10_000.times {Zlib.gunzip(d)}
0 commit comments