Example #1
0
 def test_cvsCheckout(self):
     if not cvs.isCvsInstalled():
         self.fail("Cvs is not installed on your system.  All Cvs tests will fail.")
     tempDir = mdTestUtilities.makeTempDir()
     tempRepo = mdTestUtilities.createCvsRepository(tempDir)
     checkedOutRepo = os.path.join(tempDir, "checkedOut")
     try:
         cvs.cvsCheckout(tempRepo, checkedOutRepo)
         returnValue = os.path.exists(os.path.join(checkedOutRepo, mdTestUtilities.testFileName))
         self.assertEqual(returnValue, True, "'" + mdTestUtilities.testFileName + "' did not exist after cvs.cvsCheckout(" + tempRepo + ") was called.")
     finally:
         utilityFunctions.removeDir(tempDir)
Example #2
0
 def test_isCvsRepo(self):
     if not cvs.isCvsInstalled():
         self.fail("Cvs is not installed on your system.  All Cvs tests will fail.")
     #Create repository and test if is cvs repo
     tempDir = mdTestUtilities.makeTempDir()
     tempRepo = mdTestUtilities.createCvsRepository(tempDir)
     try:
         returnValue = cvs.isCvsRepo(tempRepo)
         self.assertEqual(returnValue, True, "cvs.isCvsRepo(" + tempRepo + ") should have returned true.")
     finally:
         utilityFunctions.removeDir(tempDir)
     #Test if wrong path returns false
     falsePath = "http://foo/wrong/path"
     returnValue = cvs.isCvsRepo(falsePath)
     self.assertEqual(returnValue, False, "cvs.isCvsRepo(" + falsePath + ") should have returned false.")
Example #3
0
 def test_isCvsRepo(self):
     if not cvs.isCvsInstalled():
         self.fail("Cvs is not installed on your system.  All Cvs tests will fail.")
     # Create repository and test if is cvs repo
     tempDir = mdTestUtilities.makeTempDir()
     tempRepo = mdTestUtilities.createCvsRepository(tempDir)
     try:
         returnValue = cvs.isCvsRepo(tempRepo)
         self.assertEqual(returnValue, True, "cvs.isCvsRepo(" + tempRepo + ") should have returned true.")
     finally:
         utilityFunctions.removeDir(tempDir)
     # Test if wrong path returns false
     falsePath = "http://foo/wrong/path"
     returnValue = cvs.isCvsRepo(falsePath)
     self.assertEqual(returnValue, False, "cvs.isCvsRepo(" + falsePath + ") should have returned false.")
Example #4
0
 def test_cvsCheckout(self):
     if not cvs.isCvsInstalled():
         self.fail("Cvs is not installed on your system.  All Cvs tests will fail.")
     tempDir = mdTestUtilities.makeTempDir()
     tempRepo = mdTestUtilities.createCvsRepository(tempDir)
     checkedOutRepo = os.path.join(tempDir, "checkedOut")
     try:
         cvs.cvsCheckout(tempRepo, checkedOutRepo)
         returnValue = os.path.exists(os.path.join(checkedOutRepo, mdTestUtilities.testFileName))
         self.assertEqual(
             returnValue,
             True,
             "'"
             + mdTestUtilities.testFileName
             + "' did not exist after cvs.cvsCheckout("
             + tempRepo
             + ") was called.",
         )
     finally:
         utilityFunctions.removeDir(tempDir)
Example #5
0
 def test_isCvsInstalled(self):
     returnValue = cvs.isCvsInstalled()
     self.assertEqual(returnValue, True, "Cvs is not installed on your system.  All Cvs tests will fail.")
Example #6
0
 def test_isCvsInstalled(self):
     returnValue = cvs.isCvsInstalled()
     self.assertEqual(returnValue, True, "Cvs is not installed on your system.  All Cvs tests will fail.")