Sha256: 527a87af2324c48f2448afd0198b7f522331d930d328133d9745d701d610685d

Contents?: true

Size: 599 Bytes

Versions: 11

Compression:

Stored size: 599 Bytes

Contents

# encoding: UTF-8

# Copyright 2012 Twitter, Inc
# http://www.apache.org/licenses/LICENSE-2.0

require 'spec_helper'

include TwitterCldr

describe Bignum do
  describe "#localize" do
    it "should localize with the given locale, English by default" do
      num = 9719791287349172340823094829
      num.should be_a(Bignum)
      loc_num = num.localize
      loc_num.should be_a(LocalizedNumber)
      loc_num.locale.should == :en
      loc_num.base_obj.should == num

      loc_num = num.localize(:it)
      loc_num.should be_a(LocalizedNumber)
      loc_num.locale.should == :it
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
twitter_cldr-1.7.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.6.2 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.6.1 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.6.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.5.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.4.1 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.4.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.3.6 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.3.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.2.0 spec/core_ext/numbers/bignum_spec.rb
twitter_cldr-1.1.0 spec/ext/numbers/bignum_spec.rb