diff options
Diffstat (limited to 'activesupport/test/number_helper_test.rb')
-rw-r--r-- | activesupport/test/number_helper_test.rb | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/activesupport/test/number_helper_test.rb b/activesupport/test/number_helper_test.rb index 8f6eb91e71..dc0c34d4e2 100644 --- a/activesupport/test/number_helper_test.rb +++ b/activesupport/test/number_helper_test.rb @@ -244,23 +244,6 @@ module ActiveSupport end end - def test_number_to_human_size_with_si_prefix - assert_deprecated do - [@instance_with_helpers, TestClassWithClassNumberHelpers, ActiveSupport::NumberHelper].each do |number_helper| - assert_equal "3 Bytes", number_helper.number_to_human_size(3.14159265, prefix: :si) - assert_equal "123 Bytes", number_helper.number_to_human_size(123.0, prefix: :si) - assert_equal "123 Bytes", number_helper.number_to_human_size(123, prefix: :si) - assert_equal "1.23 KB", number_helper.number_to_human_size(1234, prefix: :si) - assert_equal "12.3 KB", number_helper.number_to_human_size(12345, prefix: :si) - assert_equal "1.23 MB", number_helper.number_to_human_size(1234567, prefix: :si) - assert_equal "1.23 GB", number_helper.number_to_human_size(1234567890, prefix: :si) - assert_equal "1.23 TB", number_helper.number_to_human_size(1234567890123, prefix: :si) - assert_equal "1.23 PB", number_helper.number_to_human_size(1234567890123456, prefix: :si) - assert_equal "1.23 EB", number_helper.number_to_human_size(1234567890123456789, prefix: :si) - end - end - end - def test_number_to_human_size_with_options_hash [@instance_with_helpers, TestClassWithClassNumberHelpers, ActiveSupport::NumberHelper].each do |number_helper| assert_equal "1.2 MB", number_helper.number_to_human_size(1234567, precision: 2) |