Exemple #1
0
 def test_dev_zero(self):
     (pairs, fname) = xdd_file_transfer.parseSpec('/dev/zero')
     self.assertEqual('/dev/zero', fname)
     self.assertEqual([], pairs)
Exemple #2
0
 def test_single_user_host(self):
     (pairs, fname) = xdd_file_transfer.parseSpec('user@host:file')
     self.assertEqual('file', fname)
     self.assertEqual(1, len(pairs))
     self.assertEqual(('user', 'host'), pairs[0])
Exemple #3
0
 def test_multi_user_host3(self):
     (pairs, fname) = xdd_file_transfer.parseSpec('user1@host1,host2:file')
     self.assertEqual('file', fname)
     self.assertEqual(2, len(pairs))
     self.assertEqual(('user1', 'host1'), pairs[0])
     self.assertEqual((None, 'host2'), pairs[1])
Exemple #4
0
 def test_no_host(self):
     (pairs, fname) = xdd_file_transfer.parseSpec('file')
     self.assertEqual('file', fname)
     self.assertEqual(0, len(pairs))