From fcc69d5a602fb1fa0ef9fa7303ba97253cac66bd Mon Sep 17 00:00:00 2001 From: Alexander Alekhin Date: Sun, 22 Sep 2019 11:28:41 +0000 Subject: [PATCH] core(test): fix check conditions --- modules/core/test/test_io.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/modules/core/test/test_io.cpp b/modules/core/test/test_io.cpp index a2a601600b..55e8f3499e 100644 --- a/modules/core/test/test_io.cpp +++ b/modules/core/test/test_io.cpp @@ -795,10 +795,10 @@ static void test_filestorage_basic(int write_flags, const char* suffix_name, boo EXPECT_EQ(_em_in.depth(), _em_out.depth()); EXPECT_TRUE(_em_in.empty()); - EXPECT_EQ(_2d_in.rows , _2d_out.rows); - EXPECT_EQ(_2d_in.cols , _2d_out.cols); - EXPECT_EQ(_2d_in.dims , _2d_out.dims); - EXPECT_EQ(_2d_in.depth(), _2d_out.depth()); + ASSERT_EQ(_2d_in.rows , _2d_out.rows); + ASSERT_EQ(_2d_in.cols , _2d_out.cols); + ASSERT_EQ(_2d_in.dims , _2d_out.dims); + ASSERT_EQ(_2d_in.depth(), _2d_out.depth()); errors = 0; for(int i = 0; i < _2d_out.rows; ++i) @@ -819,16 +819,16 @@ static void test_filestorage_basic(int write_flags, const char* suffix_name, boo } } - EXPECT_EQ(_nd_in.rows , _nd_out.rows); - EXPECT_EQ(_nd_in.cols , _nd_out.cols); - EXPECT_EQ(_nd_in.dims , _nd_out.dims); - EXPECT_EQ(_nd_in.depth(), _nd_out.depth()); + ASSERT_EQ(_nd_in.rows , _nd_out.rows); + ASSERT_EQ(_nd_in.cols , _nd_out.cols); + ASSERT_EQ(_nd_in.dims , _nd_out.dims); + ASSERT_EQ(_nd_in.depth(), _nd_out.depth()); EXPECT_EQ(0, cv::norm(_nd_in, _nd_out, NORM_INF)); - EXPECT_EQ(_rd_in.rows , _rd_out.rows); - EXPECT_EQ(_rd_in.cols , _rd_out.cols); - EXPECT_EQ(_rd_in.dims , _rd_out.dims); - EXPECT_EQ(_rd_in.depth(), _rd_out.depth()); + ASSERT_EQ(_rd_in.rows , _rd_out.rows); + ASSERT_EQ(_rd_in.cols , _rd_out.cols); + ASSERT_EQ(_rd_in.dims , _rd_out.dims); + ASSERT_EQ(_rd_in.depth(), _rd_out.depth()); EXPECT_EQ(0, cv::norm(_rd_in, _rd_out, NORM_INF)); } }