@if "%{TestFrameWork}" == "QtQuickTest" #include @if "%{UseSetupCode}" === "true" #include "setup.h" QUICK_TEST_MAIN_WITH_SETUP(example, Setup) @else QUICK_TEST_MAIN(example) @endif @endif @if "%{TestFrameWork}" == "GTest" %{Cpp:LicenseTemplate}\ #include int main(int argc, char *argv[]) { ::testing::InitGoogleTest(&argc, argv); return RUN_ALL_TESTS(); } @endif @if "%{TestFrameWork}" == "BoostTest" #define BOOST_TEST_MODULE My test module #include BOOST_AUTO_TEST_SUITE( %{TestSuiteName} ) BOOST_AUTO_TEST_CASE( %{TestCaseName} ) { BOOST_TEST( true /* test assertion */ ); } BOOST_AUTO_TEST_SUITE_END() @endif @if "%{TestFrameWork}" == "BoostTest_dyn" #define BOOST_TEST_DYN_LINK #define BOOST_TEST_MODULE My test module #include @endif @if "%{TestFrameWork}" == "Catch2" @if "%{Catch2NeedsQt}" == "true" #define CATCH_CONFIG_RUNNER @else #define CATCH_CONFIG_MAIN @endif #include @if "%{Catch2NeedsQt}" == "true" #include int main(int argc, char** argv) { QGuiApplication app(argc, argv); return Catch::Session().run(argc, argv); } @endif @endif