ts: refactor OpenCV tests
- removed tr1 usage (dropped in C++17) - moved includes of vector/map/iostream/limits into ts.hpp - require opencv_test + anonymous namespace (added compile check) - fixed norm() usage (must be from cvtest::norm for checks) and other conflict functions - added missing license headers
This commit is contained in:
@@ -41,8 +41,7 @@
|
||||
|
||||
#include "test_precomp.hpp"
|
||||
|
||||
using namespace cv;
|
||||
using namespace std;
|
||||
namespace opencv_test { namespace {
|
||||
|
||||
template <typename T, typename compute>
|
||||
class ShapeBaseTest : public cvtest::BaseTest
|
||||
@@ -63,7 +62,7 @@ public:
|
||||
{
|
||||
for (int j = 0; j < NSN; ++j)
|
||||
{
|
||||
stringstream filename;
|
||||
std::stringstream filename;
|
||||
filename << cvtest::TS::ptr()->get_data_path()
|
||||
<< "shape/mpeg_test/" << *i << "-" << j + 1 << ".png";
|
||||
filenames.push_back(filename.str());
|
||||
@@ -321,3 +320,5 @@ TEST(computeDistance, regression_4976)
|
||||
EXPECT_NEAR(d1, 26.4196891785, 1e-3) << "HausdorffDistanceExtractor";
|
||||
EXPECT_NEAR(d2, 0.25804194808, 1e-3) << "ShapeContextDistanceExtractor";
|
||||
}
|
||||
|
||||
}} // namespace
|
||||
|
||||
Reference in New Issue
Block a user