From e307d9efa88bf75f18517d861f27dc31b5f03bbc Mon Sep 17 00:00:00 2001 From: Benjamin Walsh Date: Tue, 28 Feb 2017 20:21:54 -0500 Subject: [PATCH] tests/common/timeout_order: reset test case thread to original prio That was an oversight that should not have caused any problem. However, the test harness expects the test's thread to be higher prio than the test suite's thread that spawns it, because the test suite reuses the stack space for the next test, if there is one. Change-Id: Iad951118278abf0d9c23012d78ed56b75bc2958a Signed-off-by: Benjamin Walsh --- tests/kernel/common/src/timeout_order.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/kernel/common/src/timeout_order.c b/tests/kernel/common/src/timeout_order.c index 497c84cd13f9fc..ae8cc849069529 100644 --- a/tests/kernel/common/src/timeout_order.c +++ b/tests/kernel/common/src/timeout_order.c @@ -67,6 +67,9 @@ void timeout_order_test(void) k_thread_priority_set(k_current_get(), prio + 1); assert_equal(k_poll(poll_events, NUM_TIMEOUTS, 2000), 0, ""); + + k_thread_priority_set(k_current_get(), prio - 1); + for (ii = 0; ii < NUM_TIMEOUTS; ii++) { assert_equal(poll_events[ii].state, K_POLL_STATE_SEM_AVAILABLE, "");