From 1d5e662109b45fdde8b56bf036565cc8d372839d Mon Sep 17 00:00:00 2001 From: dec05eba Date: Tue, 5 Jun 2018 14:35:35 +0200 Subject: Fix tests built twice instead of once --- backend/ninja/Ninja.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/backend/ninja/Ninja.cpp b/backend/ninja/Ninja.cpp index c72c99f..45fb9cb 100644 --- a/backend/ninja/Ninja.cpp +++ b/backend/ninja/Ninja.cpp @@ -995,20 +995,17 @@ namespace backend buildPath += TINYDIR_STRING("/sibs-build/release"); break; } + Result buildFileResult = ninja.build(sibsTestConfig, buildPath.c_str()); if (!buildFileResult) return buildFileResult; - - Result buildResult = ninja.compile(buildPath.c_str()); - if (!buildResult) - return buildResult; // Convenient to have project setup to tests as well if(config.isMainProject()) { - buildResult = buildCompilationDatabase(buildPath.c_str()); - if(!buildResult) - return buildResult; + buildFileResult = buildCompilationDatabase(buildPath.c_str()); + if(!buildFileResult) + return buildFileResult; } FileString testExecutableName = buildPath; -- cgit v1.2.3