1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

[rubygems/rubygems] Simplify bundle update --ruby specs

They don't need to run that many commands, and the new version is also
more readable in my opinion.

efff3e3210
This commit is contained in:
David Rodríguez 2020-06-07 14:54:36 +02:00 committed by Hiroshi SHIBATA
parent 66b327af56
commit 8d7ed194cb
Notes: git 2020-06-18 19:15:21 +09:00

View file

@ -712,12 +712,11 @@ RSpec.describe "bundle update --ruby" do
::RUBY_PATCHLEVEL = 100 ::RUBY_PATCHLEVEL = 100
ruby '~> 2.1.0' ruby '~> 2.1.0'
G G
bundle "update --ruby"
end end
context "when the Gemfile removes the ruby" do context "when the Gemfile removes the ruby" do
before do before do
install_gemfile <<-G gemfile <<-G
::RUBY_VERSION = '2.1.4' ::RUBY_VERSION = '2.1.4'
::RUBY_PATCHLEVEL = 222 ::RUBY_PATCHLEVEL = 222
G G
@ -742,7 +741,7 @@ RSpec.describe "bundle update --ruby" do
context "when the Gemfile specified an updated Ruby version" do context "when the Gemfile specified an updated Ruby version" do
before do before do
install_gemfile <<-G gemfile <<-G
::RUBY_VERSION = '2.1.4' ::RUBY_VERSION = '2.1.4'
::RUBY_PATCHLEVEL = 222 ::RUBY_PATCHLEVEL = 222
ruby '~> 2.1.0' ruby '~> 2.1.0'
@ -771,7 +770,7 @@ RSpec.describe "bundle update --ruby" do
context "when a different Ruby is being used than has been versioned" do context "when a different Ruby is being used than has been versioned" do
before do before do
install_gemfile <<-G gemfile <<-G
::RUBY_VERSION = '2.2.2' ::RUBY_VERSION = '2.2.2'
::RUBY_PATCHLEVEL = 505 ::RUBY_PATCHLEVEL = 505
ruby '~> 2.1.0' ruby '~> 2.1.0'
@ -786,7 +785,7 @@ RSpec.describe "bundle update --ruby" do
context "when updating Ruby version and Gemfile `ruby`" do context "when updating Ruby version and Gemfile `ruby`" do
before do before do
install_gemfile <<-G gemfile <<-G
::RUBY_VERSION = '1.8.3' ::RUBY_VERSION = '1.8.3'
::RUBY_PATCHLEVEL = 55 ::RUBY_PATCHLEVEL = 55
ruby '~> 1.8.0' ruby '~> 1.8.0'