build: fix "ambiguous call" (MSVS2010)

This commit is contained in:
Alexander Alekhin 2017-06-08 00:40:35 +03:00
parent 515e01e649
commit 781515c514

View File

@ -267,7 +267,8 @@ TEST_P (CountNonZeroND, ndim)
data = 0;
EXPECT_EQ(0, cv::countNonZero(data));
data = Scalar::all(1);
EXPECT_EQ(pow(ONE_SIZE, dims), cv::countNonZero(data));
int expected = static_cast<int>(pow(static_cast<float>(ONE_SIZE), dims));
EXPECT_EQ(expected, cv::countNonZero(data));
}
INSTANTIATE_TEST_CASE_P(Core, CountNonZeroND,