Merge branch 'ci/fix_cpp_leak_test_case' into 'master'

test(cpp): fixed cpp test case mem leak

Closes IDFCI-3108

See merge request espressif/esp-idf!41585
This commit is contained in:
Marius Vikhammer
2025-08-29 09:53:59 +08:00

View File

@@ -268,7 +268,7 @@ TEST_CASE("call destructors for thread_local classes CXX", "[misc]")
is_tls_class_destructor_called = false;
s_slow_init_sem = xSemaphoreCreateCounting(1, 0);
xTaskCreate(test_thread_local_destructors, "test_thread_local_destructors", 2048, NULL, 10, NULL);
vTaskDelay(1); /* Triggers IDLE task to call prvCheckTasksWaitingTermination() which cleans task-specific data */
vTaskDelay(10); /* Triggers IDLE task to call prvCheckTasksWaitingTermination() which cleans task-specific data */
TEST_ASSERT_TRUE(xSemaphoreTake(s_slow_init_sem, 500 / portTICK_PERIOD_MS));
vSemaphoreDelete(s_slow_init_sem);
TEST_ASSERT_TRUE(is_tls_class_destructor_called);