diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-08-05 09:25:39 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-08-05 09:25:39 +0000 |
commit | 359d53787821dc287d0411565801d54791f0a9c6 (patch) | |
tree | ee038ea590732e9c0e0acba7e96453c4e0ff0d25 /test/ruby | |
parent | b35f5db57ebd756361cfa41555f1c652ec49499b (diff) | |
download | ruby-359d53787821dc287d0411565801d54791f0a9c6.tar.gz |
* marshal.c (w_float): should not append a dot if no fractal part
exists. [ruby-dev:41936]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28868 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby')
-rw-r--r-- | test/ruby/test_marshal.rb | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/ruby/test_marshal.rb b/test/ruby/test_marshal.rb index d78183192c..f3d86277dd 100644 --- a/test/ruby/test_marshal.rb +++ b/test/ruby/test_marshal.rb @@ -40,6 +40,11 @@ class TestMarshal < Test::Unit::TestCase obj = (x.to_f + y.to_f / z.to_f) * Math.exp(w.to_f / (x.to_f + y.to_f / z.to_f)) assert_equal obj, Marshal.load(Marshal.dump(obj)) } + + bug3659 = '[ruby-dev:41936]' + [1.0, 10.0, 100.0, 110.0].each {|x| + assert_equal(x, Marshal.load(Marshal.dump(x)), bug3659) + } end StrClone = String.clone |