X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDRO_tests%2Ftest_HYDROData_LandCoverMap.cxx;h=b2c3ac69534cdae00d138ae0a9ba00461bce8cf9;hb=69d34b8c8738dabdf6cf814d0b4796af48f0d18d;hp=e715c51d4d0409224677e93b282bf8e1fadd1a03;hpb=a47eb7ba7586e0802310b3712d674654cae1b194;p=modules%2Fhydro.git diff --git a/src/HYDRO_tests/test_HYDROData_LandCoverMap.cxx b/src/HYDRO_tests/test_HYDROData_LandCoverMap.cxx index e715c51d..b2c3ac69 100644 --- a/src/HYDRO_tests/test_HYDROData_LandCoverMap.cxx +++ b/src/HYDRO_tests/test_HYDROData_LandCoverMap.cxx @@ -20,6 +20,7 @@ #include #include #include +#include #include #include #include @@ -85,7 +86,14 @@ void test_HYDROData_LandCoverMap::test_add_2_objects() TestViewer::show( aMap->GetShape(), AIS_Shaded, true ); TestViewer::AssertEqual( "LandCoverMap_Add_2_Objects" ); - //TODO: check the types + HYDROData_LandCoverMap::Iterator anIt( aMap ); + CPPUNIT_ASSERT_EQUAL( true, anIt.More() ); + CPPUNIT_ASSERT_EQUAL( QString( "test1" ), anIt.StricklerType() ); + anIt.Next(); + CPPUNIT_ASSERT_EQUAL( true, anIt.More() ); + CPPUNIT_ASSERT_EQUAL( QString( "test2" ), anIt.StricklerType() ); + anIt.Next(); + CPPUNIT_ASSERT_EQUAL( false, anIt.More() ); aDoc->Close(); } @@ -113,7 +121,14 @@ void test_HYDROData_LandCoverMap::test_split_by_polyline() //TestViewer::show( aWire, QColor(), 0 ); TestViewer::AssertEqual( "LandCoverMap_Split_1" ); - //TODO: check the types + HYDROData_LandCoverMap::Iterator anIt( aMap ); + CPPUNIT_ASSERT_EQUAL( true, anIt.More() ); + CPPUNIT_ASSERT_EQUAL( QString( "test1" ), anIt.StricklerType() ); + anIt.Next(); + CPPUNIT_ASSERT_EQUAL( true, anIt.More() ); + CPPUNIT_ASSERT_EQUAL( QString( "test1" ), anIt.StricklerType() ); + anIt.Next(); + CPPUNIT_ASSERT_EQUAL( false, anIt.More() ); aDoc->Close(); }