tests: kernel: move the multiprocessing test to new ztest

Migrate the testsuite tests/kernel/mp to the new ztest API.

Signed-off-by: Enjia Mai <enjia.mai@intel.com>
This commit is contained in:
Enjia Mai 2022-08-11 00:19:58 +08:00 committed by Carles Cufí
parent 3a1d9735fc
commit fd1cd21aff
2 changed files with 3 additions and 7 deletions

View file

@ -1,4 +1,5 @@
CONFIG_ZTEST=y
CONFIG_ZTEST_NEW_API=y
CONFIG_SMP=n
# Must have this on where available, otherwise the linker will place

View file

@ -91,7 +91,7 @@ FUNC_NORETURN void cpu1_fn(void *arg)
*
* @see arch_start_cpu()
*/
void test_mp_start(void)
ZTEST(multiprocessing, test_mp_start)
{
cpu_arg = 12345;
@ -103,9 +103,4 @@ void test_mp_start(void)
zassert_true(cpu_running, "cpu1 didn't start");
}
void test_main(void)
{
ztest_test_suite(multiprocessing,
ztest_unit_test(test_mp_start));
ztest_run_test_suite(multiprocessing);
}
ZTEST_SUITE(multiprocessing, NULL, NULL, NULL, NULL, NULL);