diff options
author | Koichi Sasada <ko1@atdot.net> | 2021-12-15 00:13:15 +0900 |
---|---|---|
committer | Koichi Sasada <ko1@atdot.net> | 2021-12-15 15:04:34 +0900 |
commit | 04aab3c2592a2234921fb715c1ff9f36a58828ca (patch) | |
tree | 56f502442e2010671b9045bd8cdb77b69f00f3dd /test/ruby | |
parent | 0eafba36103f5526c489fc5dd3d958d97e11a2c2 (diff) | |
download | ruby-04aab3c2592a2234921fb715c1ff9f36a58828ca.tar.gz |
fix test
Diffstat (limited to 'test/ruby')
-rw-r--r-- | test/ruby/test_env.rb | 7 |
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; |