Project

General

Profile

Actions

Bug #19762

closed

rubyspec refers wrongly ruby version instead of gem versions

Added by nobu (Nobuyoshi Nakada) 10 months ago. Updated 10 months ago.

Status:
Closed
Target version:
-
[ruby-core:114115]

Description

$ git grep ruby_version_is spec/ruby/library/ | grep -F -v -e /rbconfig/ -e /objectspace/ -e /coverage/ -e /fiber/ | wc -l
193

Except for libraries excluded with grep -v in the above, the others are default gems and their own versions which are unrelated to RUBY_VERSION.

version_is must be used with appropriate versions instead of ruby_version_is, for example:

spec/ruby/library/bigdecimal/remainder_spec.rb:57:  version_is BigDecimal::VERSION, ""..."3.1.4" do
spec/ruby/library/datetime/to_time_spec.rb:22:  version_is(date_version, '3.2.3') do
spec/ruby/library/logger/device/close_spec.rb:18:  version_is Logger::VERSION, ""..."1.4.0" do
spec/ruby/library/logger/device/close_spec.rb:25:  version_is Logger::VERSION, "1.4.0" do
spec/ruby/library/logger/device/write_spec.rb:38:  version_is Logger::VERSION, ""..."1.4.0" do
spec/ruby/library/logger/device/write_spec.rb:45:  version_is Logger::VERSION, "1.4.0" do
spec/ruby/library/matrix/unitary_spec.rb:17:    version_is((Matrix::const_defined?(:VERSION) ? Matrix::VERSION : "0.1.0"), "0.3.0") do
spec/ruby/library/openssl/config/freeze_spec.rb:6:version_is(OpenSSL::VERSION, ""..."2.2") do
spec/ruby/library/stringio/initialize_spec.rb:299:    version_is(stringio_version, "0.0.3"..."0.1.1")
spec/ruby/library/time/to_datetime_spec.rb:17:  version_is(date_version, '3.2.3') do

Updated by nobu (Nobuyoshi Nakada) 10 months ago

  • Description updated (diff)

To make each own versions work properly, behavioral changes need bump up even before releases.
Since default gems are synced automatically now, it may be better to bump up just after releases like csv and so on.

Updated by Eregon (Benoit Daloze) 10 months ago

Thanks for filing the issues, I replied on the ruby/spec issue.
Do you have an example where it causes problems?
Is it not trivial to fix in that case?

Updated by Eregon (Benoit Daloze) 10 months ago

  • Status changed from Open to Closed

Thank you nobu for fixing this!

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0