summaryrefslogtreecommitdiff
path: root/include/test_util.h
diff options
context:
space:
mode:
authorJett Rink <jettrink@chromium.org>2019-04-16 13:43:03 -0600
committerchrome-bot <chrome-bot@chromium.org>2019-04-24 15:51:44 -0700
commitc6254cee9684a92c81863b4576312cf8db97cab6 (patch)
treefb6a77bc2396343a2bee98f80b001c192d3a060f /include/test_util.h
parente08a71fd05bfc9e32dd64b7e15840e7232d72788 (diff)
downloadchrome-ec-c6254cee9684a92c81863b4576312cf8db97cab6.tar.gz
tests: make lighbar test easier to debug
This test was failing and it is easier to comment out tests that are passing to debug. I needed to add a precondition so each test would pass on its own. I also needed to remove the static modifier to allow each test to be comment out. BRANCH=none BUG=none TEST=builds and passes Change-Id: Ib2a7c0948aee363e1552835222a9700225993e46 Signed-off-by: Jett Rink <jettrink@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/1570605 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Diffstat (limited to 'include/test_util.h')
-rw-r--r--include/test_util.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/test_util.h b/include/test_util.h
index c85986b229..b30b663ffb 100644
--- a/include/test_util.h
+++ b/include/test_util.h
@@ -12,6 +12,9 @@
#include "console.h"
#include "stack_trace.h"
+/* This allows tests to be easily commented out in run_test for debugging */
+#define test_static static __attribute__((unused))
+
#define RUN_TEST(n) \
do { \
ccprintf("Running %s...", #n); \