[infra] Add srcmap step to code coverage job (follow-up #1547). (#1868)

This commit is contained in:
Max Moroz 2018-10-11 13:52:49 -07:00 committed by GitHub
parent 93eec08bbc
commit fdd28c42e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 24 additions and 0 deletions

View File

@ -92,6 +92,15 @@ def get_build_steps(project_dir):
],
'dir': 'oss-fuzz/projects/' + name,
},
{
'name':
image,
'args': [
'bash', '-c',
'srcmap > /workspace/srcmap.json && cat /workspace/srcmap.json'
],
'env': ['OSSFUZZ_REVISION=$REVISION_ID'],
},
]
env = CONFIGURATION[:]
@ -204,6 +213,21 @@ def get_build_steps(project_dir):
}
)
# Upload srcmap.
srcmap_upload_url = UPLOAD_URL_FORMAT.format(
project=project_name, type='srcmap', date=report_date)
srcmap_upload_url = srcmap_upload_url.rstrip('/') + '.json'
build_steps.append(
{
'name': 'gcr.io/cloud-builders/gsutil',
'args': [
'cp',
'/workspace/srcmap.json',
srcmap_upload_url,
],
}
)
# Update the latest report information file for ClusterFuzz.
latest_report_info_url = build_project.get_signed_url(
LATEST_REPORT_INFO_URL.format(project=project_name),