aboutsummaryrefslogtreecommitdiffstats
path: root/test/ruby
diff options
context:
space:
mode:
authorKoichi Sasada <ko1@atdot.net>2021-12-15 00:13:15 +0900
committerKoichi Sasada <ko1@atdot.net>2021-12-15 15:04:34 +0900
commit04aab3c2592a2234921fb715c1ff9f36a58828ca (patch)
tree56f502442e2010671b9045bd8cdb77b69f00f3dd /test/ruby
parent0eafba36103f5526c489fc5dd3d958d97e11a2c2 (diff)
downloadruby-04aab3c2592a2234921fb715c1ff9f36a58828ca.tar.gz
fix test
Diffstat (limited to 'test/ruby')
-rw-r--r--test/ruby/test_env.rb7
1 files changed, 4 insertions, 3 deletions
diff --git a/test/ruby/test_env.rb b/test/ruby/test_env.rb
index 2529b66ad6..02be1ba74b 100644
--- a/test/ruby/test_env.rb
+++ b/test/ruby/test_env.rb
@@ -1360,19 +1360,20 @@ class TestEnv < Test::Unit::TestCase
def test_huge_value_in_ractor
assert_ractor(<<-"end;")
huge_value = "bar" * 40960
- r = Ractor.new do |v|
+ r = Ractor.new huge_value do |v|
ENV["foo"] = "bar"
#{str_for_yielding_exception_class("ENV['foo'] = v ")}
Ractor.yield ENV["foo"]
end
+
if /mswin/ =~ RUBY_PLATFORM
#{str_for_assert_raise_on_yielded_exception_class(Errno::EINVAL, "r")}
- huge_value, result = r.take
+ result = r.take
assert_equal("bar", result)
else
exception_class = r.take
assert_equal(NilClass, exception_class)
- huge_value, result = r.take
+ result = r.take
assert_equal(huge_value, result)
end
end;