Salome HOME
correct selection mode activation
[modules/hydro.git] / src / HYDRO_tests / test_HYDROData_PolylineXY.cxx
index 99b61069f176803719f92e44a540f220e17fd2ff..95a89ee86bb8bc1074e2554fb872a164a8b19e2b 100644 (file)
@@ -42,13 +42,14 @@ void test_HYDROData_PolylineXY::testPolyline()
   NCollection_Sequence<bool>                              aSectClosures;
   aPolyline->GetSections( aSectNames, aSectTypes, aSectClosures );
 
-  CPPUNIT_ASSERT( aSectNames.Value( 0 ) == "Section_1" );
-  CPPUNIT_ASSERT( aSectTypes.Value( 0 ) == HYDROData_PolylineXY::SECTION_POLYLINE );
-  CPPUNIT_ASSERT( aSectClosures.Value( 0 ) == false );
-
-  CPPUNIT_ASSERT( aSectNames.Value( 1 ) == "Section_2" );
-  CPPUNIT_ASSERT( aSectTypes.Value( 1 ) == HYDROData_PolylineXY::SECTION_SPLINE );
-  CPPUNIT_ASSERT( aSectClosures.Value( 1 ) == true );
+  CPPUNIT_ASSERT_EQUAL( 2, aSectNames.Size() );
+  CPPUNIT_ASSERT( aSectNames.Value( 1 ) == "Section_1" );
+  CPPUNIT_ASSERT( aSectTypes.Value( 1 ) == HYDROData_PolylineXY::SECTION_POLYLINE );
+  CPPUNIT_ASSERT( aSectClosures.Value( 1 ) == false );
+
+  CPPUNIT_ASSERT( aSectNames.Value( 2 ) == "Section_2" );
+  CPPUNIT_ASSERT( aSectTypes.Value( 2 ) == HYDROData_PolylineXY::SECTION_SPLINE );
+  CPPUNIT_ASSERT( aSectClosures.Value( 2 ) == true );
 
   aDoc->Close();
 }