def _clone_repo(self): """Function attempts to clone the git repo associated with the entry""" success = True if os.path.exists(self._gitCloneLocation): self._logger.log(Logger.info, "Git repo already exist, checking for updates...") self._update_branch() self._logger.log(Logger.success, "Changes if any, have been merged...") else: self._logger.log(Logger.info, "Attempting to clone repo...") cmd = ["git", "clone", self._gitURL, self._gitCloneLocation] if StaticHandler.execcmd(cmd): self._logger.log(Logger.success, "Cloning successful.") self._logger.log(Logger.info, "Checking out branch " + self._gitBranch + "...") self._update_branch() else: self._logger.log(Logger.error, "Failed to clone repo, skipping...") success = False self._testData["tests"]["clone"] = success return success
def _clone_repo(self): """Function attempts to clone the git repo associated with the entry""" success = True if os.path.exists(self._gitCloneLocation): self._logger.log( Logger.info, "Git repo already exist, checking for updates...") self._update_branch() self._logger.log(Logger.success, "Changes if any, have been merged...") else: self._logger.log(Logger.info, "Attempting to clone repo...") cmd = ["git", "clone", self._gitURL, self._gitCloneLocation] if StaticHandler.execcmd(cmd): self._logger.log(Logger.success, "Cloning successful.") self._logger.log( Logger.info, "Checking out branch " + self._gitBranch + "...") self._update_branch() else: self._logger.log(Logger.error, "Failed to clone repo, skipping...") success = False self._testData["tests"]["clone"] = success return success