1
0
mirror of https://github.com/opencv/opencv_contrib.git synced 2025-10-20 12:55:15 +08:00
Files
opencv_contrib/modules/dnn/test/test_main.cpp
Vitaliy Lyudvichenko 6d3cb8080c Refinement of BlobShape API explicit BlobShape(int,int) constructor was removed
BlobShape::all(int, int) substitutes explicit BlobShape(int,int)
added new intuitive constructors: BlobShape(s0); BlobShape(s0, s1)...
added corresponding tests
2016-06-16 21:03:51 +03:00

32 lines
464 B
C++

#include "test_precomp.hpp"
CV_TEST_MAIN("")
namespace cvtest
{
using namespace cv;
using namespace cv::dnn;
TEST(BlobShape_SimpleConstr, Regression)
{
BlobShape sd;
BlobShape s1(0);
EXPECT_EQ(s1.dims(), 1);
EXPECT_EQ(s1[0], 0);
BlobShape s2(0, 0);
EXPECT_EQ(s2.dims(), 2);
EXPECT_EQ(s2[0], 0);
EXPECT_EQ(s2[1], 0);
}
TEST(BlobShape_EmptyFill, Regression)
{
BlobShape s(10, (int*)NULL);
EXPECT_EQ(s.dims(), 10);
}
}