From e0d00e48a677257f82c9feed4a930cdfc6bb6f05 Mon Sep 17 00:00:00 2001 From: Christian Zimmermann Date: Mon, 11 Sep 2017 09:58:03 +0200 Subject: [PATCH] im com --- src/multi_array_operation.cc | 2 ++ src/op_unit_test.cc | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/multi_array_operation.cc b/src/multi_array_operation.cc index 0e30e72..d8f8525 100644 --- a/src/multi_array_operation.cc +++ b/src/multi_array_operation.cc @@ -54,6 +54,7 @@ namespace MultiArrayTools template std::shared_ptr > makeBlock(const std::vector& vec, size_t stepSize, size_t blockSize) { + VCHECK(stepSize); if(stepSize == 0){ return std::make_shared >(vec, 0, blockSize); } @@ -68,6 +69,7 @@ namespace MultiArrayTools template std::shared_ptr > makeBlock(std::vector& vec, size_t stepSize, size_t blockSize) { + VCHECK(stepSize); if(stepSize == 0){ return std::make_shared >(vec, 0, blockSize); } diff --git a/src/op_unit_test.cc b/src/op_unit_test.cc index 2f2e797..d743049 100644 --- a/src/op_unit_test.cc +++ b/src/op_unit_test.cc @@ -110,7 +110,7 @@ namespace { EXPECT_EQ( fabs( res.at('f') - (0.373+8.215) ) < 0.0001, true ); EXPECT_EQ( fabs( res.at('g') - (7.192+5.063) ) < 0.0001, true ); } - /* + TEST_F(OpTest_MDim, ExecOp1) { MultiArray res(sr2ptr,sr4ptr); @@ -132,7 +132,7 @@ namespace { EXPECT_EQ( fabs( res.at(mkt('3','B')) - (0.373 * 4.790) ) < 0.0001, true ); } - + /* TEST_F(OpTest_MDim, ExecOp2) { MultiArray res(mr1ptr,sr4ptr);