From 8d7ed194cbf0e116af9183cf7347aded1ac37172 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Rodr=C3=ADguez?= Date: Sun, 7 Jun 2020 14:54:36 +0200 Subject: [PATCH] [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. https://github.com/rubygems/rubygems/commit/efff3e3210 --- spec/bundler/commands/update_spec.rb | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/spec/bundler/commands/update_spec.rb b/spec/bundler/commands/update_spec.rb index b6d3e08996..b2761f112d 100644 --- a/spec/bundler/commands/update_spec.rb +++ b/spec/bundler/commands/update_spec.rb @@ -712,12 +712,11 @@ RSpec.describe "bundle update --ruby" do ::RUBY_PATCHLEVEL = 100 ruby '~> 2.1.0' G - bundle "update --ruby" end context "when the Gemfile removes the ruby" do before do - install_gemfile <<-G + gemfile <<-G ::RUBY_VERSION = '2.1.4' ::RUBY_PATCHLEVEL = 222 G @@ -742,7 +741,7 @@ RSpec.describe "bundle update --ruby" do context "when the Gemfile specified an updated Ruby version" do before do - install_gemfile <<-G + gemfile <<-G ::RUBY_VERSION = '2.1.4' ::RUBY_PATCHLEVEL = 222 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 before do - install_gemfile <<-G + gemfile <<-G ::RUBY_VERSION = '2.2.2' ::RUBY_PATCHLEVEL = 505 ruby '~> 2.1.0' @@ -786,7 +785,7 @@ RSpec.describe "bundle update --ruby" do context "when updating Ruby version and Gemfile `ruby`" do before do - install_gemfile <<-G + gemfile <<-G ::RUBY_VERSION = '1.8.3' ::RUBY_PATCHLEVEL = 55 ruby '~> 1.8.0'