speedup unit tests compilation

This commit is contained in:
2018-12-11 22:05:25 +07:00
parent ed352855a7
commit d845543433
3 changed files with 12 additions and 5 deletions

View File

@@ -9,9 +9,5 @@ set_target_properties(${PROJECT_NAME} PROPERTIES
CXX_STANDARD_REQUIRED YES
CXX_EXTENSIONS NO)
if(MSVC)
target_compile_options(${PROJECT_NAME} PRIVATE /bigobj)
endif(MSVC)
enable_testing()
add_test(${PROJECT_NAME} ${PROJECT_NAME})

View File

@@ -4,12 +4,14 @@
* Copyright (C) 2018 Matvey Cherevko
******************************************************************************/
#define CATCH_CONFIG_MAIN
#define CATCH_CONFIG_FAST_COMPILE
#include "catch.hpp"
#include "promise.hpp"
namespace pr = promise_hpp;
#include <cstring>
namespace
{
struct obj_t {

9
tests_main.cpp Normal file
View File

@@ -0,0 +1,9 @@
/*******************************************************************************
* This file is part of the "promise.hpp"
* For conditions of distribution and use, see copyright notice in LICENSE.md
* Copyright (C) 2018 Matvey Cherevko
******************************************************************************/
#define CATCH_CONFIG_MAIN
#define CATCH_CONFIG_FAST_COMPILE
#include "catch.hpp"