diff options
author | Andre Arko <andre@arko.net> | 2010-11-12 16:46:57 -0600 |
---|---|---|
committer | Andre Arko <andre@arko.net> | 2010-11-13 01:14:43 -0600 |
commit | 32e3cdf367d19d9207c388ce3a3f045d78242d28 (patch) | |
tree | 954d9e98f0d267b42896e98705b8ed0cff9fac9c /spec/support | |
parent | 9db91026fe4f8daa2a7814550206d5a68e6334eb (diff) | |
download | bundler-32e3cdf367d19d9207c388ce3a3f045d78242d28.tar.gz |
rescue failed shell-outs to `which`
closes #664
Diffstat (limited to 'spec/support')
-rw-r--r-- | spec/support/sudo.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/support/sudo.rb b/spec/support/sudo.rb index 5992d56a69..5f62640de3 100644 --- a/spec/support/sudo.rb +++ b/spec/support/sudo.rb @@ -1,7 +1,7 @@ module Spec module Sudo def self.present? - @which_sudo ||= `which sudo`.strip + @which_sudo ||= `which sudo`.strip rescue '' !@which_sudo.empty? && ENV['BUNDLER_SUDO_TESTS'] end |