当前位置: 首页>>代码示例>>Python>>正文


Python Fingerprint.validate_for_build方法代码示例

本文整理汇总了Python中jenkinsapi.fingerprint.Fingerprint.validate_for_build方法的典型用法代码示例。如果您正苦于以下问题:Python Fingerprint.validate_for_build方法的具体用法?Python Fingerprint.validate_for_build怎么用?Python Fingerprint.validate_for_build使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在jenkinsapi.fingerprint.Fingerprint的用法示例。


在下文中一共展示了Fingerprint.validate_for_build方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _verify_download

# 需要导入模块: from jenkinsapi.fingerprint import Fingerprint [as 别名]
# 或者: from jenkinsapi.fingerprint.Fingerprint import validate_for_build [as 别名]
 def _verify_download(self, fspath):
     """
     Verify that a downloaded object has a valid fingerprint.
     """
     local_md5 = self._md5sum(fspath)
     fp = Fingerprint(self.build.job.jenkins.baseurl, local_md5, self.build.job.jenkins)
     return fp.validate_for_build(os.path.basename(fspath), self.build.job.name, self.build.buildno)
开发者ID:117111302,项目名称:jenkinsapi,代码行数:9,代码来源:artifact.py

示例2: _verify_download

# 需要导入模块: from jenkinsapi.fingerprint import Fingerprint [as 别名]
# 或者: from jenkinsapi.fingerprint.Fingerprint import validate_for_build [as 别名]
 def _verify_download(self, fspath, strict_validation):
     """
     Verify that a downloaded object has a valid fingerprint.
     """
     local_md5 = self._md5sum(fspath)
     baseurl = self.build.job.jenkins.baseurl
     fp = Fingerprint(baseurl, local_md5, self.build.job.jenkins)
     valid = fp.validate_for_build(os.path.basename(fspath), self.build.job.name, self.build.buildno)
     if not valid or (fp.unknown and strict_validation):  # strict = 404 as invalid
         raise ArtifactBroken("Artifact %s seems to be broken, check %s" % (local_md5, baseurl))
     return True
开发者ID:CBNL,项目名称:jenkinsapi,代码行数:13,代码来源:artifact.py

示例3: validate_fingerprint_for_build

# 需要导入模块: from jenkinsapi.fingerprint import Fingerprint [as 别名]
# 或者: from jenkinsapi.fingerprint.Fingerprint import validate_for_build [as 别名]
 def validate_fingerprint_for_build(self, digest, filename, job, build):
     obj_fingerprint = Fingerprint(self.baseurl, digest, jenkins_obj=self)
     return obj_fingerprint.validate_for_build(filename, job, build)
开发者ID:aamerine,项目名称:jenkinsapi,代码行数:5,代码来源:jenkins.py


注:本文中的jenkinsapi.fingerprint.Fingerprint.validate_for_build方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。