Esempio n. 1
0
 def testRemoteRepositoryRefResolving(self):
     remote_repo = RemoteRepository(self.dirname)
     for ref_name in ('master', 'tag_name'):
         self.assertEquals(remote_repo._getCommitByRefName(ref_name).hash,
                           self.initHash)
     try:
         remote_repo._getCommitByRefName('nonexistent ref')
     except NonexistentRefException:
         pass # ok
     else:
         self.fail("Did not fail")
Esempio n. 2
0
 def testRemoteRepository(self):
     remote_repo = RemoteRepository(self.dirname)
     branches = remote_repo.getBranches()
     self.assertEqual(set(branch.name for branch in branches),
                      set(['master']))