We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 983ae63 commit 587bd58Copy full SHA for 587bd58
test/test_securerandom.rb
@@ -21,7 +21,7 @@ def test_s_random_bytes_is_fork_safe
21
SecureRandom.random_bytes(8)
22
pid, v1 = forking_random_bytes
23
assert(check_forking_random_bytes(pid, v1), 'Process ID not recycled?')
24
- end if ENV["CI"]
+ end if ENV["CI"] && RUBY_PLATFORM =~ /darwin/ && `sw_vers -productVersion`.to_i > 13 # for Apple Silicon
25
26
def forking_random_bytes
27
r, w = IO.pipe
@@ -38,7 +38,7 @@ def forking_random_bytes
38
end
39
40
def check_forking_random_bytes(target_pid, target)
41
- 65536.times do
+ (65536 * 1.5).to_i.times do
42
pid = fork {
43
if $$ == target_pid
44
v2 = SecureRandom.random_bytes(8)
0 commit comments