mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* test/ruby/test_float.rb (test_float): test literal, not sprintf.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14458 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
85143195da
commit
3ce6e61a7b
1 changed files with 2 additions and 0 deletions
|
@ -11,6 +11,8 @@ class TestFloat < Test::Unit::TestCase
|
|||
assert_equal(3, 2.6.round)
|
||||
assert_equal(-2, (-2.4).truncate)
|
||||
assert((13.4 % 1 - 0.4).abs < 0.0001)
|
||||
assert_equal(36893488147419111424,
|
||||
36893488147419107329.0.to_i)
|
||||
assert_equal("36893488147419111424",
|
||||
sprintf("%20.0f", 36893488147419107329.0))
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue