From 41349bb1e8532b4a72ede912c169cf91208ac450 Mon Sep 17 00:00:00 2001 From: Hiroshi SHIBATA Date: Wed, 16 Sep 2026 21:21:08 +0900 Subject: [PATCH] Require NUMBER_OF_PROCESSORS in test_nprocessors A missing variable turned the lower bound into 0, which the existing assertion already covers. Co-Authored-By: Claude Fable 5.1 --- test/etc/test_etc.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/etc/test_etc.rb b/test/etc/test_etc.rb index 611832e7899..d0e19f31cee 100644 --- a/test/etc/test_etc.rb +++ b/test/etc/test_etc.rb @@ -168,7 +168,7 @@ class TestEtc < Test::Unit::TestCase n = Etc.nprocessors assert_operator(1, :<=, n) if /mswin|mingw/ =~ RUBY_PLATFORM - assert_operator(ENV["NUMBER_OF_PROCESSORS"].to_i, :<=, n) + assert_operator(Integer(ENV.fetch("NUMBER_OF_PROCESSORS")), :<=, n) end end