summaryrefslogtreecommitdiff
path: root/spec/ruby/library/bigdecimal/to_d_spec.rb
blob: 8e20901fd9f6e8d23824ffafc3ae66331e58f98e (plain)
1
2
3
4
5
6
7
8
9
10
11
require_relative '../../spec_helper'
require 'bigdecimal'
require 'bigdecimal/util'


describe "Float#to_d" do
  it "returns appropriate BigDecimal zero for signed zero" do
    -0.0.to_d.sign.should == -1
    0.0.to_d.sign.should == 1
  end
end