diff options
Diffstat (limited to 'test/-ext-/string/test_capacity.rb')
-rw-r--r-- | test/-ext-/string/test_capacity.rb | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/test/-ext-/string/test_capacity.rb b/test/-ext-/string/test_capacity.rb index 0cb7c00761..bcca64d85a 100644 --- a/test/-ext-/string/test_capacity.rb +++ b/test/-ext-/string/test_capacity.rb @@ -23,7 +23,7 @@ class Test_StringCapacity < Test::Unit::TestCase def test_s_new_capacity assert_equal("", String.new(capacity: 1000)) assert_equal(String, String.new(capacity: 1000).class) - assert_equal(10000, capa(String.new(capacity: 10000))) + assert_equal(10_000, capa(String.new(capacity: 10_000))) assert_equal("", String.new(capacity: -1000)) assert_equal(capa(String.new(capacity: -10000)), capa(String.new(capacity: -1000))) @@ -66,11 +66,7 @@ class Test_StringCapacity < Test::Unit::TestCase end def embed_header_size - if GC.using_rvargc? - 2 * RbConfig::SIZEOF['void*'] + RbConfig::SIZEOF['long'] - else - 2 * RbConfig::SIZEOF['void*'] - end + 3 * RbConfig::SIZEOF['void*'] end def max_embed_len |