diff options
author | Benoit Daloze <eregontp@gmail.com> | 2024-02-12 10:56:33 +0100 |
---|---|---|
committer | Benoit Daloze <eregontp@gmail.com> | 2024-02-12 10:56:33 +0100 |
commit | b19d2409be0b7bac65e6e54cfb3bedc61419ec01 (patch) | |
tree | 9046a7aea28aa043053acc473646b40828ec3736 /spec/ruby/core/integer | |
parent | 90a746d246d51d105d7f3e0d1c2ddf7994dd2d4b (diff) |
Update to ruby/spec@ce834ad
Diffstat (limited to 'spec/ruby/core/integer')
-rw-r--r-- | spec/ruby/core/integer/coerce_spec.rb | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/spec/ruby/core/integer/coerce_spec.rb b/spec/ruby/core/integer/coerce_spec.rb index 13fe7b3321..f1f3256032 100644 --- a/spec/ruby/core/integer/coerce_spec.rb +++ b/spec/ruby/core/integer/coerce_spec.rb @@ -1,5 +1,7 @@ require_relative '../../spec_helper' +require 'bigdecimal' + describe "Integer#coerce" do context "fixnum" do describe "when given a Fixnum" do @@ -89,16 +91,13 @@ describe "Integer#coerce" do end end - ruby_version_is ""..."3.4" do - require 'bigdecimal' - context "bigdecimal" do - it "produces Floats" do - x, y = 3.coerce(BigDecimal("3.4")) - x.class.should == Float - x.should == 3.4 - y.class.should == Float - y.should == 3.0 - end + context "bigdecimal" do + it "produces Floats" do + x, y = 3.coerce(BigDecimal("3.4")) + x.class.should == Float + x.should == 3.4 + y.class.should == Float + y.should == 3.0 end end |