tests: sleep: reduce verbosity
Reduce verbosity and debug messages on the screen. Signed-off-by: Anas Nashif <anas.nashif@intel.com>
This commit is contained in:
parent
37529505ad
commit
6ba0e9c797
|
@ -72,8 +72,6 @@ static void test_objects_init(void)
|
|||
k_sem_init(&test_thread_sem, 0, UINT_MAX);
|
||||
k_sem_init(&helper_thread_sem, 0, UINT_MAX);
|
||||
k_sem_init(&task_sem, 0, UINT_MAX);
|
||||
|
||||
TC_PRINT("Kernel objects initialized\n");
|
||||
}
|
||||
|
||||
static void align_to_tick_boundary(void)
|
||||
|
@ -111,7 +109,6 @@ static void test_thread(void *p1, void *p2, void *p3)
|
|||
|
||||
k_sem_take(&test_thread_sem, K_FOREVER);
|
||||
|
||||
TC_PRINT("Testing normal expiration of k_sleep()\n");
|
||||
align_to_tick_boundary();
|
||||
|
||||
start_tick = k_uptime_get_32();
|
||||
|
@ -125,7 +122,6 @@ static void test_thread(void *p1, void *p2, void *p3)
|
|||
return;
|
||||
}
|
||||
|
||||
TC_PRINT("Testing: test thread sleep + helper thread wakeup test\n");
|
||||
k_sem_give(&helper_thread_sem); /* Activate helper thread */
|
||||
align_to_tick_boundary();
|
||||
|
||||
|
@ -139,7 +135,6 @@ static void test_thread(void *p1, void *p2, void *p3)
|
|||
return;
|
||||
}
|
||||
|
||||
TC_PRINT("Testing: test thread sleep + isr offload wakeup test\n");
|
||||
k_sem_give(&helper_thread_sem); /* Activate helper thread */
|
||||
align_to_tick_boundary();
|
||||
|
||||
|
@ -153,7 +148,6 @@ static void test_thread(void *p1, void *p2, void *p3)
|
|||
return;
|
||||
}
|
||||
|
||||
TC_PRINT("Testing: test thread sleep + main wakeup test thread\n");
|
||||
k_sem_give(&task_sem); /* Activate task */
|
||||
align_to_tick_boundary();
|
||||
|
||||
|
@ -216,16 +210,12 @@ ZTEST(sleep, test_sleep)
|
|||
0, 0, NULL, TEST_THREAD_PRIORITY,
|
||||
0, K_NO_WAIT);
|
||||
|
||||
TC_PRINT("Test thread started: id = %p\n", test_thread_id);
|
||||
|
||||
helper_thread_id = k_thread_create(&helper_thread_data,
|
||||
helper_thread_stack, THREAD_STACK,
|
||||
helper_thread,
|
||||
0, 0, NULL, HELPER_THREAD_PRIORITY,
|
||||
0, K_NO_WAIT);
|
||||
|
||||
TC_PRINT("Helper thread started: id = %p\n", helper_thread_id);
|
||||
|
||||
/* Activate test_thread */
|
||||
k_sem_give(&test_thread_sem);
|
||||
|
||||
|
@ -237,7 +227,6 @@ ZTEST(sleep, test_sleep)
|
|||
|
||||
zassert_false(test_failure, "test failure");
|
||||
|
||||
TC_PRINT("Testing kernel k_sleep()\n");
|
||||
align_to_tick_boundary();
|
||||
start_tick = k_uptime_get_32();
|
||||
k_sleep(K_SECONDS(1));
|
||||
|
|
|
@ -89,7 +89,6 @@ ZTEST_USER(sleep, test_usleep)
|
|||
}
|
||||
}
|
||||
|
||||
printk("elapsed_ms = %" PRId64 "\n", elapsed_ms);
|
||||
zassert_true(elapsed_ms >= LOWER_BOUND_MS, "short sleep");
|
||||
zassert_true(elapsed_ms <= UPPER_BOUND_MS, "overslept");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue