def test_known_hosts(self, ssh_dir):
     ssh_dir.return_value = '/tmp/foo'
     self.assertEquals(utils.known_hosts(), '/tmp/foo/known_hosts')
示例#2
0
 def test_known_hosts(self, ssh_dir):
     ssh_dir.return_value = '/tmp/foo'
     self.assertEquals(utils.known_hosts(), '/tmp/foo/known_hosts')
     ssh_dir.assert_called_with(None, None)
     self.assertEquals(utils.known_hosts('bar'), '/tmp/foo/known_hosts')
     ssh_dir.assert_called_with('bar', None)
 def test_known_hosts(self, ssh_dir):
     ssh_dir.return_value = '/tmp/foo'
     self.assertEquals(utils.known_hosts(), '/tmp/foo/known_hosts')
     ssh_dir.assert_called_with(None, None)
     self.assertEquals(utils.known_hosts('bar'), '/tmp/foo/known_hosts')
     ssh_dir.assert_called_with('bar', None)