summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Bettis <jbettis@google.com>2022-06-01 13:42:34 -0600
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2022-06-07 16:48:56 +0000
commit97a725b4f5268efc5baba77e7cd743cb3f629c62 (patch)
tree977937444634f2ce03b79d56c7859f26bfc43c1e
parentba1198cb0387369749b28834f89d55b8570bafd9 (diff)
downloadchrome-ec-97a725b4f5268efc5baba77e7cd743cb3f629c62.tar.gz
zephyr: Don't convert paths to relative in info
The CQ recipe will now convert absolute paths to relative paths as needed, so leave the paths as absolute in the lcov file. BRANCH=None BUG=b:231639771 TEST=Ran script by hand Cq-Depend: chromium:3683588 Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I1461d935ae42ad09d3617ea506911cf5b5acbb00 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3684370 Reviewed-by: Aaron Massey <aaronmassey@google.com> Commit-Queue: Jeremy Bettis <jbettis@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org>
-rwxr-xr-xzephyr/firmware_builder.py14
1 files changed, 1 insertions, 13 deletions
diff --git a/zephyr/firmware_builder.py b/zephyr/firmware_builder.py
index 1a8ce32469..21767d635a 100755
--- a/zephyr/firmware_builder.py
+++ b/zephyr/firmware_builder.py
@@ -193,7 +193,7 @@ def test(opts):
cmd = [
'/usr/bin/lcov',
'-o',
- build_dir / 'fullpaths.info',
+ build_dir / 'lcov.info',
'--rc',
'lcov_branch_coverage=1',
'-a',
@@ -211,18 +211,6 @@ def test(opts):
cwd=pathlib.Path(__file__).parent, check=True,
stdout=subprocess.PIPE, universal_newlines=True).stdout
_extract_lcov_summary('EC_ZEPHYR_TESTS', metrics, output)
- # Make filenames relative to platform/ec
- cmd = ['sed', '-e', 's|^SF:.*/platform/ec/|SF:|']
- with open(build_dir / 'fullpaths.info') as infile, open(
- build_dir / 'lcov.info', 'w'
- ) as outfile:
- subprocess.run(
- cmd,
- cwd=pathlib.Path(__file__).parent,
- stdin=infile,
- stdout=outfile,
- check=True,
- )
with open(opts.metrics, 'w') as file:
file.write(json_format.MessageToJson(metrics))