diff options
author | MerryMage <MerryMage@users.noreply.github.com> | 2016-03-20 14:58:24 +0000 |
---|---|---|
committer | MerryMage <MerryMage@users.noreply.github.com> | 2016-05-19 08:38:03 +0100 |
commit | a03f9b6fb6cdaf480737faf37b9c244f46cd1a85 (patch) | |
tree | 9f2ff1718289bc48de5d9c07fee1d3c54c3af58c /src | |
parent | 6f6af6928fdff8c807e4a4d03cfd8906e0c7c7cd (diff) |
tests: Infrastructure for unit tests
Diffstat (limited to 'src')
-rw-r--r-- | src/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/tests/CMakeLists.txt | 14 | ||||
-rw-r--r-- | src/tests/tests.cpp | 9 |
3 files changed, 24 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index de4fe716a8..1e12451607 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -5,6 +5,7 @@ add_subdirectory(common) add_subdirectory(core) add_subdirectory(video_core) add_subdirectory(audio_core) +add_subdirectory(tests) if (ENABLE_SDL2) add_subdirectory(citra) endif() diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt new file mode 100644 index 0000000000..dc476616c8 --- /dev/null +++ b/src/tests/CMakeLists.txt @@ -0,0 +1,14 @@ +set(SRCS + tests.cpp + ) + +set(HEADERS + ) + +create_directory_groups(${SRCS} ${HEADERS}) + +include_directories(../../externals/catch/single_include/) + +add_executable(tests ${SRCS} ${HEADERS}) +target_link_libraries(tests core video_core audio_core common) +target_link_libraries(tests ${PLATFORM_LIBRARIES}) diff --git a/src/tests/tests.cpp b/src/tests/tests.cpp new file mode 100644 index 0000000000..73978676f1 --- /dev/null +++ b/src/tests/tests.cpp @@ -0,0 +1,9 @@ +// Copyright 2016 Citra Emulator Project +// Licensed under GPLv2 or any later version +// Refer to the license.txt file included. + +#define CATCH_CONFIG_MAIN +#include <catch.hpp> + +// Catch provides the main function since we've given it the +// CATCH_CONFIG_MAIN preprocessor directive. |