示例#1
0
文件: log.py 项目: saik0/local-repo
	def test_store_buildlog(self):
		BuildLog.init(self.repo)

		for pkg in ['pkg1', 'pkg2', 'pkg1']:
			l, f = mkstemp(prefix='local-repo-test-buildlog-file-')
			BuildLog.store(pkg, f)
			self.assertIs(True, isfile(join(self.buildlog, pkg, basename(f))))
示例#2
0
文件: log.py 项目: yunchih/local-repo
    def test_store_buildlog(self):
        BuildLog.init(self.repo)

        for pkg in ['pkg1', 'pkg2', 'pkg1']:
            l, f = mkstemp(prefix='local-repo-test-buildlog-file-')
            BuildLog.store(pkg, f)
            self.assertIs(True, isfile(join(self.buildlog, pkg, basename(f))))
示例#3
0
	def init(path, config_file=Config.CONFIGFILE):
		''' Needs the path to repo, or the repo name if specified in the config file '''
		try:
			Config.init(path, config_file)
			LocalRepo._repo = Repo(Config.get('path', path))
			Log.init(LocalRepo._repo.path)
			BuildLog.init(LocalRepo._repo.path)
			PkgbuildLog.init(LocalRepo._repo.path)
		except LocalRepoError as e:
			LocalRepo.error(e)
示例#4
0
 def init(path, config_file=Config.CONFIGFILE):
     ''' Needs the path to repo, or the repo name if specified in the config file '''
     try:
         Config.init(path, config_file)
         LocalRepo._repo = Repo(Config.get('path', path))
         Log.init(LocalRepo._repo.path)
         BuildLog.init(LocalRepo._repo.path)
         PkgbuildLog.init(LocalRepo._repo.path)
     except LocalRepoError as e:
         LocalRepo.error(e)