Better visibility for C tests:

- turn on output-on-failure by default
 - explain how to run tests in README
This commit is contained in:
Vincent Mallet 2021-03-23 16:33:52 -07:00
parent 4f59b98185
commit dc51f5d236
2 changed files with 5 additions and 0 deletions

View File

@ -184,6 +184,7 @@ ENDIF ()
IF (MSGPACK_BUILD_TESTS)
ENABLE_TESTING ()
list(APPEND CMAKE_CTEST_ARGUMENTS "--output-on-failure")
# MEMORYCHECK_COMMAND_OPTIONS needs to place prior to CTEST_MEMORYCHECK_COMMAND
SET (MEMORYCHECK_COMMAND_OPTIONS "--leak-check=full --show-leak-kinds=definite,possible --error-exitcode=1")
FIND_PROGRAM(CTEST_MEMORYCHECK_COMMAND NAMES valgrind)

View File

@ -82,6 +82,10 @@ How to build:
$ make
$ sudo make install
How to run tests:
$ make test
When you use the C part of `msgpack-c`, you need to build and link the library. By default, both static/shared libraries are built. If you want to build only static library, set `BUILD_SHARED_LIBS=OFF` to cmake. If you want to build only shared library, set `BUILD_SHARED_LIBS=ON`.
#### GUI on Windows