You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by rm...@apache.org on 2023/01/23 23:00:25 UTC

[logging-log4cxx] branch master updated: Make multithreadtest optional due to its instability (#185)

This is an automated email from the ASF dual-hosted git repository.

rmiddleton pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/logging-log4cxx.git


The following commit(s) were added to refs/heads/master by this push:
     new 2b81723f Make multithreadtest optional due to its instability (#185)
2b81723f is described below

commit 2b81723f8c4698c7e6ec42b2a5597d529693785d
Author: Robert Middleton <rm...@users.noreply.github.com>
AuthorDate: Mon Jan 23 18:00:20 2023 -0500

    Make multithreadtest optional due to its instability (#185)
---
 src/test/cpp/CMakeLists.txt | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/test/cpp/CMakeLists.txt b/src/test/cpp/CMakeLists.txt
index 74a35e5b..751abf8c 100644
--- a/src/test/cpp/CMakeLists.txt
+++ b/src/test/cpp/CMakeLists.txt
@@ -15,6 +15,9 @@
 # limitations under the License.
 #
 
+option(ENABLE_MULTITHREAD_TEST "Enable multithread test.  Note that this test is very unstable,
+    it is mostly designed to ensure that we don't crash immediately if exit is called in a thread"  OFF)
+
 # Components required by all tests
 add_library(testingFramework STATIC abts.cpp appenderskeletontestcase.cpp logunit.cpp vectorappender.cpp writerappendertestcase.cpp )
 target_compile_definitions(testingFramework PRIVATE ${LOG4CXX_COMPILE_DEFINITIONS} ${APR_COMPILE_DEFINITIONS} ${APR_UTIL_COMPILE_DEFINITIONS} )
@@ -54,13 +57,15 @@ set(ALL_LOG4CXX_TESTS
     propertyconfiguratortest
     rollingfileappendertestcase
     streamtestcase
-    multithreadtest
     locationtest
     locationdisabledtest
 )
 if(${ENABLE_FMT_LAYOUT})
     set(ALL_LOG4CXX_TESTS ${ALL_LOG4CXX_TESTS} fmttest)
 endif()
+if(${ENABLE_MULTITHREAD_TEST})
+    set(ALL_LOG4CXX_TESTS ${ALL_LOG4CXX_TESTS} multithreadtest)
+endif()
 foreach(fileName IN LISTS ALL_LOG4CXX_TESTS)
     add_executable(${fileName} "${fileName}.cpp")
 endforeach()