summaryrefslogtreecommitdiff
path: root/spec/support
diff options
context:
space:
mode:
authorAndre Arko <andre@arko.net>2010-11-12 16:46:57 -0600
committerAndre Arko <andre@arko.net>2010-11-13 01:14:43 -0600
commit32e3cdf367d19d9207c388ce3a3f045d78242d28 (patch)
tree954d9e98f0d267b42896e98705b8ed0cff9fac9c /spec/support
parent9db91026fe4f8daa2a7814550206d5a68e6334eb (diff)
downloadbundler-32e3cdf367d19d9207c388ce3a3f045d78242d28.tar.gz
rescue failed shell-outs to `which`
closes #664
Diffstat (limited to 'spec/support')
-rw-r--r--spec/support/sudo.rb2
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