This commit is contained in:
2020-09-15 15:39:17 +03:00
parent 4f731d72a6
commit f9c1dbc661
4 changed files with 4 additions and 6 deletions

View File

@@ -6,7 +6,7 @@ macro(pip_test NAME LIBS)
set(_target pip_${NAME}_test)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${PIP_ROOT_BINARY_DIR}")
add_executable(${_target} ${_CPPS} ${_HDRS})
target_link_libraries(${_target} pip ${LIBS} gtest_main gmock_main)
target_link_libraries(${_target} pip ${LIBS} gtest_main gmock_main)
add_test(NAME ${_target} COMMAND tests)
add_custom_target(${_target}_perform ALL COMMAND ${_target})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY)

View File

@@ -1,8 +1,7 @@
#include "gtest/gtest.h"
#include "pimathmatrix.h"
template<typename Type>
bool cmpSquareMatrixWithValue(PIMathMatrix<double> matrix, Type val, int num) {
bool cmpSquareMatrixWithValue(PIMathMatrix<double> matrix, double val, int num) {
bool b = true;
for(int i = 0; i < num; i++) {
for(int j = 0; j < num; j++) {

View File

@@ -4,8 +4,7 @@
const uint rows = 3;
const uint cols = 3;
template<typename Type>
bool cmpSquareMatrixWithValue(PIMathMatrixT<rows, cols, double> matrix, Type val, int num) {
bool cmpSquareMatrixWithValue(PIMathMatrixT<rows, cols, double> matrix, double val, int num) {
bool b = true;
for(int i = 0; i < num; i++) {
for(int j = 0; j < num; j++) {