diff options
| author | Matt Robinson <matt@puppetlabs.com> | 2011-05-13 15:00:42 -0700 |
|---|---|---|
| committer | Matt Robinson <matt@puppetlabs.com> | 2011-05-13 15:00:42 -0700 |
| commit | 4b7afaa065383c4a441068a15f97ab82d2ebd3fc (patch) | |
| tree | 9ec63989d87e43e4dba65e40eb3a0067c7cacc5c /lib/puppet/util | |
| parent | d63fc34d0c6fdfbe72dafdf5d07a6cc9c6dd388e (diff) | |
| parent | 61d732231fa1d23a5e9c32bc38ec9f11430229ba (diff) | |
| download | puppet-4b7afaa065383c4a441068a15f97ab82d2ebd3fc.tar.gz puppet-4b7afaa065383c4a441068a15f97ab82d2ebd3fc.tar.xz puppet-4b7afaa065383c4a441068a15f97ab82d2ebd3fc.zip | |
Merge branch '2.7.x' into 2.7.next
* 2.7.x:
(#7469) Add license to test face so tests pass
(#7264) Docs: Clarify that subscribe/notify imply require/before
(#7468) Stub spec that tries to connect to pypi.python.org
Prevent spec failure caused by network device mock leak
Fix #7299 - do not require net/ssh for running rake spec
Resolved Conflicts:
lib/puppet/util/network_device.rb
spec/unit/util/network_device_spec.rb
Diffstat (limited to 'lib/puppet/util')
| -rw-r--r-- | lib/puppet/util/network_device/transport/ssh.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/puppet/util/network_device/transport/ssh.rb b/lib/puppet/util/network_device/transport/ssh.rb index bf0e7193c..3d7976543 100644 --- a/lib/puppet/util/network_device/transport/ssh.rb +++ b/lib/puppet/util/network_device/transport/ssh.rb @@ -2,7 +2,6 @@ require 'puppet/util/network_device' require 'puppet/util/network_device/transport' require 'puppet/util/network_device/transport/base' -require 'net/ssh' # This is an adaptation/simplification of gem net-ssh-telnet, which aims to have # a sane interface to Net::SSH. Credits goes to net-ssh-telnet authors @@ -12,6 +11,9 @@ class Puppet::Util::NetworkDevice::Transport::Ssh < Puppet::Util::NetworkDevice: def initialize super + unless Puppet.features.ssh? + raise 'Connecting with ssh to a network device requires the \'net/ssh\' ruby library' + end end def handles_login? |
