Skip to content
Commit 08498956 authored by Shihao Shen's avatar Shihao Shen Committed by Anas Nashif
Browse files

tests: kernel: pipe: testcases to improve code coverage for pipes



Added back test_pipe_alloc because the z_thread_malloc called in the
API has been updated to use k_heap instead of k_mem_pool.
Adjusted test_resource_pool_auto_free by replacing z_mem_pool_malloc
with k_heap_alloc. Added new test_k_pipe_cleanup to cover one more
branch in k_pipe_cleanup. Modified test_half_pipe_put_get to cover
branches for (reader != NULL) in k_pipe_put. Added test
test_pipe_get_put to cover branches for (writer != NULL)
in k_pipe_get. Added trivial tests to cover input validity checks.
Line coverage has been improved by 52%, function cov by 56%, and
branch cov by 46%.

Signed-off-by: default avatarShihao Shen <shihao.shen@intel.com>
parent 2638f2ec
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment