From 54d7a3bb66e9cee7472a7ed573ada1b00911d480 Mon Sep 17 00:00:00 2001 From: Darian Leung Date: Sat, 15 Oct 2022 01:45:47 +0800 Subject: [PATCH] freertos: Migrate misc tests to test app This commit migrates the "misc" tests to the test app as a component. --- components/freertos/test_apps/freertos/CMakeLists.txt | 1 + .../freertos/test_apps/freertos/misc/CMakeLists.txt | 10 ++++++++++ .../misc}/test_freertos_backported_functions.c | 0 .../freertos/misc}/test_freertos_mutex.c | 0 .../freertos/misc}/test_freertos_trace_utilities.c | 0 .../freertos/misc}/test_panic.c | 0 .../freertos/misc}/test_preemption.c | 0 .../freertos/misc}/test_tlsp_del_cb.c | 0 8 files changed, 11 insertions(+) create mode 100644 components/freertos/test_apps/freertos/misc/CMakeLists.txt rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_freertos_backported_functions.c (100%) rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_freertos_mutex.c (100%) rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_freertos_trace_utilities.c (100%) rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_panic.c (100%) rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_preemption.c (100%) rename components/freertos/{test/miscellaneous => test_apps/freertos/misc}/test_tlsp_del_cb.c (100%) diff --git a/components/freertos/test_apps/freertos/CMakeLists.txt b/components/freertos/test_apps/freertos/CMakeLists.txt index 402da75c30..d3ff742e10 100644 --- a/components/freertos/test_apps/freertos/CMakeLists.txt +++ b/components/freertos/test_apps/freertos/CMakeLists.txt @@ -6,6 +6,7 @@ cmake_minimum_required(VERSION 3.16) # type is treated as separate component set(test_types "kernel" + "misc" "performance" "port") diff --git a/components/freertos/test_apps/freertos/misc/CMakeLists.txt b/components/freertos/test_apps/freertos/misc/CMakeLists.txt new file mode 100644 index 0000000000..783c5a6af2 --- /dev/null +++ b/components/freertos/test_apps/freertos/misc/CMakeLists.txt @@ -0,0 +1,10 @@ +# Register all of the "misc" tests as a component + +# In order for the cases defined by `TEST_CASE` in "misc" to be linked into +# the final elf, the component can be registered as WHOLE_ARCHIVE +idf_component_register(SRC_DIRS "." + PRIV_REQUIRES test_utils + WHOLE_ARCHIVE) + +# Todo: Fix no-format errors +target_compile_options(${COMPONENT_LIB} PRIVATE "-Wno-format") diff --git a/components/freertos/test/miscellaneous/test_freertos_backported_functions.c b/components/freertos/test_apps/freertos/misc/test_freertos_backported_functions.c similarity index 100% rename from components/freertos/test/miscellaneous/test_freertos_backported_functions.c rename to components/freertos/test_apps/freertos/misc/test_freertos_backported_functions.c diff --git a/components/freertos/test/miscellaneous/test_freertos_mutex.c b/components/freertos/test_apps/freertos/misc/test_freertos_mutex.c similarity index 100% rename from components/freertos/test/miscellaneous/test_freertos_mutex.c rename to components/freertos/test_apps/freertos/misc/test_freertos_mutex.c diff --git a/components/freertos/test/miscellaneous/test_freertos_trace_utilities.c b/components/freertos/test_apps/freertos/misc/test_freertos_trace_utilities.c similarity index 100% rename from components/freertos/test/miscellaneous/test_freertos_trace_utilities.c rename to components/freertos/test_apps/freertos/misc/test_freertos_trace_utilities.c diff --git a/components/freertos/test/miscellaneous/test_panic.c b/components/freertos/test_apps/freertos/misc/test_panic.c similarity index 100% rename from components/freertos/test/miscellaneous/test_panic.c rename to components/freertos/test_apps/freertos/misc/test_panic.c diff --git a/components/freertos/test/miscellaneous/test_preemption.c b/components/freertos/test_apps/freertos/misc/test_preemption.c similarity index 100% rename from components/freertos/test/miscellaneous/test_preemption.c rename to components/freertos/test_apps/freertos/misc/test_preemption.c diff --git a/components/freertos/test/miscellaneous/test_tlsp_del_cb.c b/components/freertos/test_apps/freertos/misc/test_tlsp_del_cb.c similarity index 100% rename from components/freertos/test/miscellaneous/test_tlsp_del_cb.c rename to components/freertos/test_apps/freertos/misc/test_tlsp_del_cb.c