Skip to content

Commit

Permalink
Fix logger and add new unitTest
Browse files Browse the repository at this point in the history
  • Loading branch information
martel21324 committed May 28, 2024
1 parent c01aa0d commit 2409090
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 7 deletions.
2 changes: 1 addition & 1 deletion CMakeFMTVS2022vcpkg_MAM.bat
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ cmake CMakeLists.txt ^
-G "Visual Studio 17 2022" ^
-DBUILD_TYPE=Release ^
-DPARALLEL_TESTS=8 ^
-DVCPKG_ROOT=D:\FMT\FMT\vcpkg ^
-DCMAKE_TOOLCHAIN_FILE=D:\FMT\FMT\vcpkg\scripts\buildsystems\vcpkg.cmake ^
-DVCPKG_TARGET_TRIPLET=x64-windows ^
-DVCPKG_MANIFEST_MODE=ON ^
-DONNXR_DIR=D:/FMT/Dependencies/onnxruntime ^
-DMOSEK_DIR="C:/PROGRA~1/Mosek/10.1/"

Expand Down
2 changes: 1 addition & 1 deletion README.fr.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,4 +170,4 @@ MSVC ![](https://img.shields.io/badge/coverage-0%25-red)
## 💻 Build
GNU ![](https://img.shields.io/badge/build-pass-brightgreen)
MSVC ![](https://img.shields.io/badge/build-pass-brightgreen)
MSVC ![](https://img.shields.io/badge/build-broken-red)
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,4 +168,4 @@ MSVC ![](https://img.shields.io/badge/coverage-0%25-red)
## 💻 Build
GNU ![](https://img.shields.io/badge/build-pass-brightgreen)
MSVC ![](https://img.shields.io/badge/build-pass-brightgreen)
MSVC ![](https://img.shields.io/badge/build-broken-red)
3 changes: 2 additions & 1 deletion Source/FMTexponentialschedule.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright (c) 2019 Gouvernement du Québec
Copyright (c) 2019 Gouvernement du Qu�bec
SPDX-License-Identifier: LiLiQ-R-1.1
License-Filename: LICENSES/EN/LiLiQ-R11unicode.txt
Expand All @@ -12,6 +12,7 @@ License-Filename: LICENSES/EN/LiLiQ-R11unicode.txt
#include <string>
#include <vector>
#include <math.h>
#include <algorithm>


namespace Spatial
Expand Down
6 changes: 3 additions & 3 deletions Source/FMTlogger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,12 +100,12 @@ namespace Logging
FMTlogger::FMTlogger(const FMTlogger& rhs):filepath(), filestream(), mtx(), flushstream(false)
{
boost::lock_guard<boost::recursive_mutex> lock(rhs.mtx);
#if defined FMTWITHOSI
solverref.reset(new FMTsolverlogger(*rhs.solverref));
#endif
filepath=rhs.filepath;
settofile(filepath);
flushstream=rhs.flushstream;
#if defined FMTWITHOSI
solverref.reset(new FMTsolverlogger(*this));
#endif
}

FMTlogger& FMTlogger::operator = (const FMTlogger& rhs)
Expand Down
8 changes: 8 additions & 0 deletions UI/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@ if (MSVC AND WrapperSOURCES)
message("Generating build for FMTWrapper")
set(udflocation "${CMAKE_CURRENT_SOURCE_DIR}/UI/userDefineLang.xml")
list (APPEND FMTDEPENDENCIES ${udflocation})
if (NOT WITHOUT_TESTS)
FILE(GLOB FMTexecutables ${CMAKE_CURRENT_SOURCE_DIR}/UI/tests/*.cpp)
foreach(pathtosource ${FMTexecutables})
createexecutable("${pathtosource}" executablename)
target_link_libraries(${executablename} PRIVATE FMTWrapper)
target_include_directories(${executablename} PRIVATE ${WrapperINCLUDEDIR})
endforeach()
endif(NOT WITHOUT_TESTS)
else()
message("No files found in ${CMAKE_CURRENT_SOURCE_DIR}/UI/Source/ the wrapper wont be compiled headers need to be in UI/Include and sources in UI/Source")
endif(MSVC AND WrapperSOURCES)
Expand Down

0 comments on commit 2409090

Please sign in to comment.