Fixed adding results to TestRail

This commit is contained in:
yevh-berdnyk 2022-05-06 17:48:30 +03:00
parent 44a449660a
commit e219aaf2b0
No known key found for this signature in database
GPG Key ID: 0642C73C66214825
1 changed files with 5 additions and 2 deletions

View File

@ -193,8 +193,11 @@ class TestrailReport(BaseTestReport):
except IndexError:
continue
for res in results:
if re.findall(r"%s\?auth=.*#%s" % (device, str(last_testrun.first_commands[device])),
res['comment']):
if last_testrun.first_commands:
pattern = r"%s\?auth=.*#%s" % (device, str(last_testrun.first_commands[device]))
else:
pattern = device
if re.findall(pattern, res['comment']):
res_id = res['id']
try:
for geth in test.geth_paths.keys():