init: main: fix ifdef in init/main.c

Apparently I was not thinking straight when I wrote
3ca6801f967518d92d2b68bedec00ab5d253a12d (init: main: add KUnit to
kernel init) and I put an ifdef in init/main.c. This fixes that.

Signed-off-by: Brendan Higgins <brendanhiggins@google.com>
Sqaush: 3ca6801f967518d92d2b68bedec00ab5d253a12d
Change-Id: I6d47c163fdf57f5e83a4eb9479397e6d656025ac
diff --git a/include/test/test.h b/include/test/test.h
index 4b76282..b5f2d24 100644
--- a/include/test/test.h
+++ b/include/test/test.h
@@ -187,7 +187,14 @@
 
 int test_run_tests(struct test_module *module);
 
+#if IS_ENABLED(CONFIG_TEST)
 int test_executor_init(void);
+#else
+static inline int test_executor_init(void)
+{
+	return 0;
+}
+#endif
 
 void test_install_initcall(struct test_initcall *initcall);
 
diff --git a/init/main.c b/init/main.c
index 7ddbf5e..a6121ad 100644
--- a/init/main.c
+++ b/init/main.c
@@ -1145,9 +1145,7 @@
 
 	do_basic_setup();
 
-#if IS_ENABLED(CONFIG_TEST)
 	test_executor_init();
-#endif
 
 	/* Open the /dev/console on the rootfs, this should never fail */
 	if (ksys_open((const char __user *) "/dev/console", O_RDWR, 0) < 0)