未验证 提交 d985b4b1 编写于 作者: Y YUNSHEN XIE 提交者: GitHub

fix get_pr_ut error (#44787)

* fix get_pr_ut error

* fix bug
上级 4c3e13de
......@@ -60,12 +60,15 @@ class PRChecker(object):
last_commit = None
ix = 0
while True:
commits = self.pr.get_commits().get_page(ix)
for c in commits:
last_commit = c.commit
else:
try:
commits = self.pr.get_commits().get_page(ix)
if len(commits) == 0:
raise ValueError("no commit found in {} page".format(ix))
last_commit = commits[-1].commit
except Exception as e:
break
ix = ix + 1
else:
ix = ix + 1
if last_commit.message.find('test=allcase') != -1:
print('PREC test=allcase is set')
self.full_case = True
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册