diff options
author | Jeremy Bettis <jbettis@google.com> | 2022-07-12 13:27:00 -0600 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-07-13 18:43:21 +0000 |
commit | 3ee8dd3d69a467e695f4263d0aee1ebb26fced76 (patch) | |
tree | 8ba7d4454926d5afb9ea16b063abaae0af2ce18d /util/kconfig_check.py | |
parent | 87b4a3f45158b0710dec4ddb395360a8e405267c (diff) | |
download | chrome-ec-3ee8dd3d69a467e695f4263d0aee1ebb26fced76.tar.gz |
ec: Fix kconfig_check and run unit test in cq
Changed the unit test to fail if it can't find zephyr or the kconfiglib
instead of skipping, and make it pass.
Run the unit test in the CQ.
In the process, I discovered that it never used kconfiglib because of
errors with ZEPHYR_BASE not being set. Changed kconfig_check to output
the error when it falls back to no kconfiglib.
This exposed that there were missing configs in util/config_allowed.txt
BRANCH=None
BUG=b:238773780,b:181253613
TEST=make -j40 buildall && util/run_tests.sh
Change-Id: I28a050d448a40df034dd9f2305a2d17cd0797468
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3759263
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Keith Short <keithshort@chromium.org>
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Diffstat (limited to 'util/kconfig_check.py')
-rwxr-xr-x | util/kconfig_check.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/util/kconfig_check.py b/util/kconfig_check.py index 04cdf9a990..db2bc09a5b 100755 --- a/util/kconfig_check.py +++ b/util/kconfig_check.py @@ -25,6 +25,7 @@ import os import pathlib import re import sys +import traceback # Try to use kconfiglib if available, but fall back to a simple recursive grep. # This is used by U-Boot in some situations so we keep it to avoid forking this @@ -331,6 +332,8 @@ class KconfigCheck: except kconfiglib.KconfigError: # If we don't actually have access to the full Kconfig then we may # get an error. Fall back to using manual methods. + print("WARNING: kconfiglib failed", file=sys.stderr) + traceback.print_exc() kconfigs = self.scan_kconfigs( srcdir, prefix, search_paths, try_kconfiglib=False ) |