summaryrefslogtreecommitdiff
path: root/spec/support
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2017-06-21 13:33:52 -0500
committerSamuel Giddins <segiddins@segiddins.me>2017-06-23 12:43:54 -0500
commitde775593ffc43e97e3d5adec3837a1eee4c3b74b (patch)
tree2ec3cd9f8375c4c16982e80e486bb7dfa662a99d /spec/support
parent87370195728549ed989ca8b63bf6bd30b1702819 (diff)
downloadbundler-de775593ffc43e97e3d5adec3837a1eee4c3b74b.tar.gz
Get the specs passing in 1.0 mode
Diffstat (limited to 'spec/support')
-rw-r--r--spec/support/helpers.rb2
-rw-r--r--spec/support/matchers.rb12
2 files changed, 7 insertions, 7 deletions
diff --git a/spec/support/helpers.rb b/spec/support/helpers.rb
index 3e53068dee..b31b0f05c1 100644
--- a/spec/support/helpers.rb
+++ b/spec/support/helpers.rb
@@ -42,7 +42,7 @@ module Spec
end
def err
- last_command.bundler_err
+ last_command.stderr
end
def exitstatus
diff --git a/spec/support/matchers.rb b/spec/support/matchers.rb
index 4fbf44a4e0..e91f04fb29 100644
--- a/spec/support/matchers.rb
+++ b/spec/support/matchers.rb
@@ -140,8 +140,8 @@ module Spec
rescue => e
next "#{name} is not installed:\n#{indent(e)}"
end
- out.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
- actual_version, actual_platform = out.strip.split(/\s+/, 2)
+ last_command.stdout.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
+ actual_version, actual_platform = last_command.stdout.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
@@ -155,8 +155,8 @@ module Spec
rescue
next "#{name} does not have a source defined:\n#{indent(e)}"
end
- out.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
- unless out.strip == source
+ last_command.stdout.gsub!(/#{MAJOR_DEPRECATION}.*$/, "")
+ unless last_command.stdout.strip == source
next "Expected #{name} (#{version}) to be installed from `#{source}`, was actually from `#{out}`"
end
end.compact
@@ -181,9 +181,9 @@ module Spec
rescue => e
next "checking for #{name} failed:\n#{e}"
end
- next if out == "WIN"
+ next if last_command.stdout == "WIN"
next "expected #{name} to not be installed, but it was" if version.nil?
- if Gem::Version.new(out) == Gem::Version.new(version)
+ if Gem::Version.new(last_command.stdout) == Gem::Version.new(version)
next "expected #{name} (#{version}) not to be installed, but it was"
end
end.compact