Skip to content

Commit 2c2b140

Browse files
committed
Add test for Mat_::release()
1 parent 0037454 commit 2c2b140

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

modules/core/test/test_mat.cpp

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1725,4 +1725,12 @@ TEST(Core_Mat_array, SplitMerge)
17251725
EXPECT_EQ(0, countNonZero(diff));
17261726
}
17271727
}
1728-
#endif
1728+
#endif
1729+
1730+
TEST(Mat, regression_8680)
1731+
{
1732+
Mat_<Point2i> mat(3,1);
1733+
ASSERT_EQ(mat.channels(), 2);
1734+
mat.release();
1735+
ASSERT_EQ(mat.channels(), 2);
1736+
}

0 commit comments

Comments
 (0)