From 1a845656a498b24884ee0598607ab08230335285 Mon Sep 17 00:00:00 2001 From: Jeremy Bettis Date: Thu, 1 Sep 2022 14:34:10 -0600 Subject: twister: Resolve symlinks in module paths. On gitlab, in the coverage report, the ec code appears in ${CI_PROJECT_DIR}/modules/ec instead of the real path where the EC code lives. When we exclude the modules dir all that coverage gets deleted. BRANCH=None BUG=None TEST=pushed to gitlab, and ran firmware_builder.py Signed-off-by: Jeremy Bettis Change-Id: If4e4899146f6c99da229ca27ba8fac8119df2a3c Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3869310 Tested-by: Jeremy Bettis Commit-Queue: Tristan Honscheid Auto-Submit: Jeremy Bettis Reviewed-by: Tristan Honscheid Reviewed-by: Yuval Peress Commit-Queue: Jeremy Bettis --- util/twister_launcher.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/twister_launcher.py b/util/twister_launcher.py index 227d829320..af29a5e66d 100755 --- a/util/twister_launcher.py +++ b/util/twister_launcher.py @@ -77,7 +77,7 @@ def find_modules(mod_dir: Path) -> list: modules = [] for child in mod_dir.iterdir(): if child.is_dir() and (child / "zephyr" / "module.yml").exists(): - modules.append(child) + modules.append(child.resolve()) return modules @@ -91,7 +91,7 @@ def main(): # Add the EC dir as a module if not already included (resolve all paths to # account for symlinked or relative paths) - if ec_base.resolve() not in {p.resolve() for p in zephyr_modules}: + if ec_base.resolve() not in zephyr_modules: zephyr_modules.append(ec_base) # Prepare environment variables for export to Twister. Inherit the parent -- cgit v1.2.1