8b438cb97e
This includes the basic CMake infrastructure for building and executing the test suite. Four test categories have been added - unit, system/functional, GUI, and simgear unit tests. The test suite is run by typing 'make test_suite'. All of the fgfs sources are included in the new run_test_suite executable, excluding the bootstrap routine and its main() function. The test suite currently consists of a single dummy unit test for the NasalSys subsystem, and a single demonstration simgear/props unit test.
42 lines
917 B
CMake
42 lines
917 B
CMake
# Locate CppUnit.
|
|
#
|
|
# This module defines
|
|
# CPPUNIT_FOUND
|
|
# CPPUNIT_LIBRARIES
|
|
# CPPUNIT_INCLUDE_DIR
|
|
|
|
# Find CppUnit.
|
|
if (NOT CPPUNIT_LIBRARIES AND NOT CPPUNIT_INCLUDE_DIR)
|
|
# Find the headers.
|
|
find_path(CPPUNIT_INCLUDE_DIR
|
|
NAMES
|
|
cppunit/Test.h
|
|
PATHS
|
|
/usr/include
|
|
/usr/local/include
|
|
/opt/include
|
|
/opt/local/include
|
|
/sw/include
|
|
)
|
|
|
|
# Find the library.
|
|
find_library(CPPUNIT_LIBRARIES
|
|
NAMES
|
|
cppunit
|
|
PATHS
|
|
/usr/lib
|
|
/usr/local/lib
|
|
/opt/lib
|
|
/opt/local/lib
|
|
/sw/lib
|
|
)
|
|
|
|
endif ()
|
|
|
|
|
|
# Pre-set or found.
|
|
if (CPPUNIT_LIBRARIES AND CPPUNIT_INCLUDE_DIR)
|
|
set(CPPUNIT_FOUND TRUE)
|
|
message(STATUS "CppUnit library found: ${CPPUNIT_LIBRARIES}")
|
|
message(STATUS "CppUnit include directory found: ${CPPUNIT_INCLUDE_DIR}")
|
|
endif ()
|