diff options
author | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2019-06-01 12:49:40 +0300 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2019-06-09 12:44:10 +0900 |
commit | 8f37629519ad330032a38ac0e871b2912ed38a1b (patch) | |
tree | bb0529b77583d47993d8b0d608d68896aa3a5298 /spec/bundler/support/matchers.rb | |
parent | 66508992483ae5d77b56a98427c50c772341c0ac (diff) |
Merge bundler master from upstream.
Pick from 8dd59e3ba97eb80a599f8149f31bf40773b69dc0
Diffstat (limited to 'spec/bundler/support/matchers.rb')
-rw-r--r-- | spec/bundler/support/matchers.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/bundler/support/matchers.rb b/spec/bundler/support/matchers.rb index f9efe32a38..5d1a6a7919 100644 --- a/spec/bundler/support/matchers.rb +++ b/spec/bundler/support/matchers.rb @@ -133,7 +133,7 @@ module Spec rescue StandardError => e next "#{name} is not installed:\n#{indent(e)}" end - actual_version, actual_platform = last_command.stdout.strip.split(/\s+/, 2) + actual_version, actual_platform = out.strip.split(/\s+/, 2) unless Gem::Version.new(actual_version) == Gem::Version.new(version) next "#{name} was expected to be at version #{version} but was #{actual_version}" end @@ -147,7 +147,7 @@ module Spec rescue StandardError next "#{name} does not have a source defined:\n#{indent(e)}" end - unless last_command.stdout.strip == source + unless out.strip == source next "Expected #{name} (#{version}) to be installed from `#{source}`, was actually from `#{out}`" end end.compact @@ -172,9 +172,9 @@ module Spec rescue StandardError => e next "checking for #{name} failed:\n#{e}" end - next if last_command.stdout == "WIN" + next if out == "WIN" next "expected #{name} to not be installed, but it was" if version.nil? - if Gem::Version.new(last_command.stdout) == Gem::Version.new(version) + if Gem::Version.new(out) == Gem::Version.new(version) next "expected #{name} (#{version}) not to be installed, but it was" end end.compact |