зеркало из https://github.com/github/ruby.git
Deal with different Ruby versions
This commit is contained in:
Родитель
802dce4acd
Коммит
18fa7059e8
|
@ -228,7 +228,15 @@ describe "BigDecimal#round" do
|
|||
-> { BigDecimal('-Infinity').round(2) }.should_not raise_error(FloatDomainError)
|
||||
end
|
||||
|
||||
it "raise for a non-existent round mode" do
|
||||
-> { @p1_50.round(0, :nonsense) }.should raise_error(ArgumentError, "invalid rounding mode (nonsense)")
|
||||
ruby_version_is ''...'3.2' do
|
||||
it 'raise for a non-existent round mode' do
|
||||
-> { @p1_50.round(0, :nonsense) }.should raise_error(ArgumentError, "invalid rounding mode")
|
||||
end
|
||||
end
|
||||
|
||||
ruby_version_is '3.2' do
|
||||
it 'raise for a non-existent round mode' do
|
||||
-> { @p1_50.round(0, :nonsense) }.should raise_error(ArgumentError, "invalid rounding mode (nonsense)")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Загрузка…
Ссылка в новой задаче