summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnastasia Klimchuk <aklm@chromium.org>2021-09-17 11:03:43 +1000
committerNico Huber <nico.h@gmx.de>2021-10-18 12:22:23 +0000
commit83b5191399157ff7a3ade3d95974cf5e3c8a077e (patch)
treedf5faf1b7d9dbd904d5c28f36b82409c37d275a5
parentd23613cf6668b677264e5e02d4f4ac02873d307b (diff)
downloadflashrom-83b5191399157ff7a3ade3d95974cf5e3c8a077e.tar.gz
flashrom-83b5191399157ff7a3ade3d95974cf5e3c8a077e.tar.bz2
flashrom-83b5191399157ff7a3ade3d95974cf5e3c8a077e.zip
tests: Move LOG_ME to include/tests.h to be available everywhere
LOG_ME macro is very generic and can be useful anywhere in tests. Previously was only used in scope of tests.c. With time more tests are added, and more files, LOG_ME needs to be visible everywhere. BUG=b:181803212 TEST=builds and ninja test Change-Id: If7f3d256161bc8b81e996328e445cccab9a82174 Signed-off-by: Anastasia Klimchuk <aklm@chromium.org> Reviewed-on: https://review.coreboot.org/c/flashrom/+/57914 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Nico Huber <nico.h@gmx.de>
-rw-r--r--tests/include/test.h2
-rw-r--r--tests/tests.c3
2 files changed, 2 insertions, 3 deletions
diff --git a/tests/include/test.h b/tests/include/test.h
index ee7b4cf1c..bf8c4f7bd 100644
--- a/tests/include/test.h
+++ b/tests/include/test.h
@@ -35,4 +35,6 @@
*/
void *not_null(void);
+#define LOG_ME printf("%s is called\n", __func__)
+
#endif /* _TESTS_TEST_H */
diff --git a/tests/tests.c b/tests/tests.c
index 9dadddfec..329e798a2 100644
--- a/tests/tests.c
+++ b/tests/tests.c
@@ -21,9 +21,6 @@
#include <string.h>
#include <stdint.h>
-/* redefinitions/wrapping */
-#define LOG_ME printf("%s is called\n", __func__)
-
void *not_null(void)
{
return (void *)NON_ZERO;