Skip to content

Commit ac0b03e

Browse files
committed
Use the existing mechanism to adapt the timeout in MRI tests's EnvUtil
1 parent c184567 commit ac0b03e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

test/mri/tests/lib/envutil.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,9 @@ def capture_global_values
6767
end
6868
end
6969

70+
# TruffleRuby: startup can take longer, especially on highly loaded CI machines
71+
self.subprocess_timeout_scale = 2
72+
7073
def apply_timeout_scale(t)
7174
if scale = EnvUtil.subprocess_timeout_scale
7275
t * scale
@@ -77,7 +80,7 @@ def apply_timeout_scale(t)
7780
module_function :apply_timeout_scale
7881

7982
def invoke_ruby(args, stdin_data = "", capture_stdout = false, capture_stderr = false,
80-
encoding: nil, timeout: 20, reprieve: 1, timeout_error: Timeout::Error,
83+
encoding: nil, timeout: 10, reprieve: 1, timeout_error: Timeout::Error,
8184
stdout_filter: nil, stderr_filter: nil,
8285
signal: :TERM,
8386
rubybin: EnvUtil.rubybin, precommand: nil,

0 commit comments

Comments
 (0)