summaryrefslogtreecommitdiff
path: root/spec/ruby/library/bigdecimal/divide_spec.rb
blob: c62b23557dec7a6b61c406e8640bf166a984a5db (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
require_relative '../../spec_helper'
require_relative 'shared/quo'
require 'bigdecimal'

describe "BigDecimal#/" do
  it_behaves_like :bigdecimal_quo, :/, []

  before :each do
    @three = BigDecimal("3")
  end

  describe "with Rational" do
    it "produces a BigDecimal" do
      (@three / Rational(500, 2)).should == BigDecimal("0.12e-1")
    end
  end
end