catch2 running
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
add_subdirectory(testcfg)
|
||||
add_subdirectory(controller)
|
||||
|
||||
target_sources(${TARGET_NAME} PRIVATE
|
||||
|
||||
target_sources(${UNITTEST_NAME} PRIVATE
|
||||
main.cpp
|
||||
)
|
3
unittest/controller/CMakeLists.txt
Normal file
3
unittest/controller/CMakeLists.txt
Normal file
@ -0,0 +1,3 @@
|
||||
target_sources(${UNITTEST_NAME} PRIVATE
|
||||
testThermalController.cpp
|
||||
)
|
7
unittest/controller/testThermalController.cpp
Normal file
7
unittest/controller/testThermalController.cpp
Normal file
@ -0,0 +1,7 @@
|
||||
#include <catch2/catch_test_macros.hpp>
|
||||
|
||||
TEST_CASE( "Thermal Controller" , "[ThermalController]") {
|
||||
bool test = true;
|
||||
REQUIRE( test == true);
|
||||
|
||||
}
|
@ -1,7 +1,15 @@
|
||||
#include "fsfw/serviceinterface/ServiceInterfaceStream.h"
|
||||
#include "fsfw_tests/unit/CatchRunner.h"
|
||||
#include <stdio.h>
|
||||
|
||||
#include <catch2/catch_session.hpp>
|
||||
|
||||
int main(int argc, char* argv[]) {
|
||||
// fsfwtest::customMain(argc, argv);
|
||||
puts("unittests");
|
||||
|
||||
|
||||
// Catch internal function call
|
||||
int result = Catch::Session().run(argc, argv);
|
||||
|
||||
// global clean-up
|
||||
return result;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user