spec/beaker/hypervisor/vagrant_spec.rb in beaker-vagrant-0.6.5 vs spec/beaker/hypervisor/vagrant_spec.rb in beaker-vagrant-0.6.6
- old
+ new
@@ -482,11 +482,12 @@
it "can generate a ssh-config file" do
expect( Tempfile ).to receive( :new ).with( "#{host.name}").and_return( file )
expect( file ).to receive( :write ).with("Host ip.address.for.#{name}\n HostName 127.0.0.1\n User root\n Port 2222\n UserKnownHostsFile /dev/null\n StrictHostKeyChecking no\n PasswordAuthentication no\n IdentityFile /home/root/.vagrant.d/insecure_private_key\n IdentitiesOnly no")
vagrant.set_ssh_config( host, 'root' )
- expect( host['ssh'] ).to be === { :config => file.path }
+ expect( host[:vagrant_ssh_config] ).to be === '/path/sshconfig'
+ expect( host['ssh'][:config]).to be === false
expect( host['user']).to be === 'root'
end
context "when :forward_ssh_agent is false" do
it "should not change IdentitiesOnly to no" do
@@ -496,10 +497,11 @@
expect( Tempfile ).to receive( :new ).with( "#{host.name}").and_return( file )
expect( file ).to receive( :write ).with("Host ip.address.for.#{name}\n HostName 127.0.0.1\n User root\n Port 2222\n UserKnownHostsFile /dev/null\n StrictHostKeyChecking no\n PasswordAuthentication no\n IdentityFile /home/root/.vagrant.d/insecure_private_key\n IdentitiesOnly yes")
vagrant.set_ssh_config( host, 'root' )
- expect( host['ssh'] ).to be === { :config => file.path }
+ expect( host[:vagrant_ssh_config] ).to be === '/path/sshconfig'
+ expect( host['ssh'][:config]).to be === false
expect( host['user']).to be === 'root'
end
end
end