File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -80,11 +80,10 @@ def remove(gemfile_path, lockfile_path)
8080 def conservative_version ( spec )
8181 version = spec . version
8282 return ">= 0" if version . nil?
83- segments = version . segments
8483 seg_end_index = version >= Gem ::Version . new ( "1.0" ) ? 1 : 2
8584
8685 prerelease_suffix = version . to_s . delete_prefix ( version . release . to_s ) if version . prerelease?
87- "#{ version_prefix } #{ segments [ 0 ..seg_end_index ] . join ( "." ) } #{ prerelease_suffix } "
86+ "#{ version_prefix } #{ version . segments [ 0 ..seg_end_index ] . join ( "." ) } #{ prerelease_suffix } "
8887 end
8988
9089 def version_prefix
Original file line number Diff line number Diff line change 5151 end
5252
5353 it "version requirement becomes ~> major.minor.patch.pre when resolved version is < 1.0" do
54- # Ruby 3.3 on Windows has a native crash (SEGV in rb_ary_cmp during Array#join) related to Object Shape optimization.
55- skip "Ruby 3.3 on Windows crashes with SEGV in Array#join" if Gem . win_platform? && RUBY_VERSION . start_with? ( "3.3." )
5654 bundle "add 'cat'"
5755 expect ( bundled_app_gemfile . read ) . to match ( /gem "cat", "~> 0.12.3.pre"/ )
5856 expect ( the_bundle ) . to include_gems "cat 0.12.3.pre"
5957 end
6058
6159 it "version requirement becomes ~> major.minor.pre when resolved version is > 1.0.pre" do
62- # Ruby 3.3 on Windows has a native crash (SEGV in rb_ary_cmp during Array#join) related to Object Shape optimization.
63- skip "Ruby 3.3 on Windows crashes with SEGV in Array#join" if Gem . win_platform? && RUBY_VERSION . start_with? ( "3.3." )
6460 bundle "add 'dog'"
6561 expect ( bundled_app_gemfile . read ) . to match ( /gem "dog", "~> 1.1.pre"/ )
6662 expect ( the_bundle ) . to include_gems "dog 1.1.3.pre"
You can’t perform that action at this time.
0 commit comments