summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authork0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-27 16:42:41 +0000
committerk0kubun <k0kubun@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-12-27 16:42:41 +0000
commitfcc5a19e2f9801217691a842250db937de3ea5ee (patch)
treee92fcd377445ebcb5446c0c2deded25014ade70b
parent006afb858d77efe9f63d056cf54c3bb578cd39da (diff)
test_method.rb: do not kill RubyCI openSUSE machine
with NoMemoryError on TestMethod#test_splat_long_array. https://rubyci.org/logs/rubyci.s3.amazonaws.com/opensuseleap/ruby-trunk/log/20181227T080002Z.log.html.gz Maybe better to check /proc/meminfo instead of /etc/os-release. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66594 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--test/ruby/test_method.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/test_method.rb b/test/ruby/test_method.rb
index 65d9e3d2e1..a9051b81fa 100644
--- a/test/ruby/test_method.rb
+++ b/test/ruby/test_method.rb
@@ -949,6 +949,10 @@ class TestMethod < Test::Unit::TestCase
end
def test_splat_long_array
+ if File.exist?('/etc/os-release') && File.read('/etc/os-release').include?('openSUSE Leap')
+ # For RubyCI's openSUSE machine http://rubyci.s3.amazonaws.com/opensuseleap/ruby-trunk/recent.html, which tends to die with NoMemoryError here.
+ skip 'do not exhaust memory on RubyCI openSUSE Leap machine'
+ end
n = 10_000_000
assert_equal n , rest_parameter(*(1..n)).size, '[Feature #10440]'
end