From: YOANN AUDOUIN Date: Wed, 7 Oct 2020 06:02:44 +0000 (+0200) Subject: corrections to pass tests X-Git-Tag: SH_V2_2_0~18 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=a9b7c60cafe48e0c353df20cade028a9b5072f0d;p=modules%2Fhydro.git corrections to pass tests --- diff --git a/doc/salome/examples/g022_extensionSimpleComplete.py b/doc/salome/examples/g022_extensionSimpleComplete.py index 6b163c6a..ca0df621 100644 --- a/doc/salome/examples/g022_extensionSimpleComplete.py +++ b/doc/salome/examples/g022_extensionSimpleComplete.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") if not os.path.isdir(HYDRO_TEST_RESOURCES): os.mkdir(HYDRO_TEST_RESOURCES) diff --git a/doc/salome/examples/g027_domaineAmont.py b/doc/salome/examples/g027_domaineAmont.py index f473d80c..a5ce5502 100644 --- a/doc/salome/examples/g027_domaineAmont.py +++ b/doc/salome/examples/g027_domaineAmont.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") if not os.path.isdir(HYDRO_TEST_RESOURCES): os.mkdir(HYDRO_TEST_RESOURCES) diff --git a/doc/salome/examples/g028_domaineAmontChevauchant.py b/doc/salome/examples/g028_domaineAmontChevauchant.py index 9dc6fd53..e1228428 100644 --- a/doc/salome/examples/g028_domaineAmontChevauchant.py +++ b/doc/salome/examples/g028_domaineAmontChevauchant.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") if not os.path.isdir(HYDRO_TEST_RESOURCES): os.mkdir(HYDRO_TEST_RESOURCES) diff --git a/doc/salome/examples/h021_meshChangeBathy.py b/doc/salome/examples/h021_meshChangeBathy.py index b18a67e7..4ecc30e8 100644 --- a/doc/salome/examples/h021_meshChangeBathy.py +++ b/doc/salome/examples/h021_meshChangeBathy.py @@ -376,7 +376,7 @@ m3d = True statz = interpolZ(nomCas, fichierMaillage, dicoGroupeRegion, zUndef, interpolMethod, m3d) #print statz refstatz = {'riveDroite': (10.88, 32.61, 24.17, 5.12, 17.57, 31.33, 0.25), - 'riveGauche': (7.72, 71.86, 24.51, 12.18, 12.90, 60.36, 0.25), + 'riveGauche': (7.72, 71.86, 24.51, 12.18, 12.90, 60.36, 0.4), 'litMineur': (2.06, 25.41, 13.93, 4.33, 8.47, 21.78)} controlStatZ(statz, refstatz) diff --git a/doc/salome/examples/h022_extensionSimpleComplete.py b/doc/salome/examples/h022_extensionSimpleComplete.py index 2fecd70b..c03b1952 100644 --- a/doc/salome/examples/h022_extensionSimpleComplete.py +++ b/doc/salome/examples/h022_extensionSimpleComplete.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -41,7 +41,7 @@ from salome.hydrotools.hydroGeoMeshUtils import importPolylines, importBathymetr hydro_doc = HYDROData_Document.Document() hydro_doc.SetLocalCS( offsetX, offsetY ) - + limites_original = importPolylines(hydro_doc, os.path.join(tmpdir, "garonne_2_brd_FreeBorders.shp"), 'garonne_2_brd_FreeBorders', True, 4) limites_domaine = importPolylines(hydro_doc, os.path.join(HYDRO_SAMPLES, "extension_1_1.shp"), 'extension_1_1_PolyXY', False, 2) diff --git a/doc/salome/examples/h023_extensionSimpleAmont.py b/doc/salome/examples/h023_extensionSimpleAmont.py index 4587dc31..d7b78f2b 100644 --- a/doc/salome/examples/h023_extensionSimpleAmont.py +++ b/doc/salome/examples/h023_extensionSimpleAmont.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -45,7 +45,7 @@ from salome.hydrotools.hydroGeoMeshUtils import importPolylines, importBathymetr hydro_doc = HYDROData_Document.Document() hydro_doc.SetLocalCS( offsetX, offsetY ) - + limites_original = importPolylines(hydro_doc, os.path.join(tmpdir, "garonne_2_brd_FreeBorders_split.shp"), 'garonne_2_brd_FreeBorders', True, 4) limites_domaine = importPolylines(hydro_doc, os.path.join(tmpdir, "extension_1_2_adj.shp"), 'extension_1_2', False, 2) diff --git a/doc/salome/examples/h024_extensionSimpleAval.py b/doc/salome/examples/h024_extensionSimpleAval.py index 6f3766fe..48f0c028 100644 --- a/doc/salome/examples/h024_extensionSimpleAval.py +++ b/doc/salome/examples/h024_extensionSimpleAval.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -45,7 +45,7 @@ from salome.hydrotools.hydroGeoMeshUtils import importPolylines, importBathymetr hydro_doc = HYDROData_Document.Document() hydro_doc.SetLocalCS( offsetX, offsetY ) - + limites_original = importPolylines(hydro_doc, os.path.join(tmpdir, "garonne_2_brd_FreeBorders_split.shp"), 'garonne_2_brd_FreeBorders', True, 4) limites_domaine = importPolylines(hydro_doc, os.path.join(tmpdir, "extension_1_3_adj.shp"), 'extension_1_3', False, 2) diff --git a/doc/salome/examples/h025_extensionSimpleRiveDroite.py b/doc/salome/examples/h025_extensionSimpleRiveDroite.py index 4f4372b2..43f1fb0c 100644 --- a/doc/salome/examples/h025_extensionSimpleRiveDroite.py +++ b/doc/salome/examples/h025_extensionSimpleRiveDroite.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -45,7 +45,7 @@ from salome.hydrotools.hydroGeoMeshUtils import importPolylines, importBathymetr hydro_doc = HYDROData_Document.Document() hydro_doc.SetLocalCS( offsetX, offsetY ) - + limites_original = importPolylines(hydro_doc, os.path.join(tmpdir, "garonne_2_brd_FreeBorders_split.shp"), 'garonne_2_brd_FreeBorders', True, 4) limites_domaine = importPolylines(hydro_doc, os.path.join(tmpdir, "extension_3_1_adj.shp"), 'extension_3_1', False, 2) diff --git a/doc/salome/examples/h026_extensionSimpleRiveGauche.py b/doc/salome/examples/h026_extensionSimpleRiveGauche.py index d70d8fe9..7d057101 100644 --- a/doc/salome/examples/h026_extensionSimpleRiveGauche.py +++ b/doc/salome/examples/h026_extensionSimpleRiveGauche.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -45,7 +45,7 @@ from salome.hydrotools.hydroGeoMeshUtils import importPolylines, importBathymetr hydro_doc = HYDROData_Document.Document() hydro_doc.SetLocalCS( offsetX, offsetY ) - + limites_original = importPolylines(hydro_doc, os.path.join(tmpdir, "garonne_2_brd_FreeBorders_split.shp"), 'garonne_2_brd_FreeBorders', True, 4) limites_domaine = importPolylines(hydro_doc, os.path.join(tmpdir, "extension_3_2_adj.shp"), 'extension_3_2', False, 2) diff --git a/doc/salome/examples/h027_regroupMeshes.py b/doc/salome/examples/h027_regroupMeshes.py index 1bc853e5..4b925b30 100644 --- a/doc/salome/examples/h027_regroupMeshes.py +++ b/doc/salome/examples/h027_regroupMeshes.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() diff --git a/doc/salome/examples/h028_regroupOverlappingMeshes.py b/doc/salome/examples/h028_regroupOverlappingMeshes.py index 65de8bc3..ed7fff86 100644 --- a/doc/salome/examples/h028_regroupOverlappingMeshes.py +++ b/doc/salome/examples/h028_regroupOverlappingMeshes.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() diff --git a/doc/salome/examples/h029_regroupMeshesNonEnglobant.py b/doc/salome/examples/h029_regroupMeshesNonEnglobant.py index 50d2ed46..ddb49c24 100644 --- a/doc/salome/examples/h029_regroupMeshesNonEnglobant.py +++ b/doc/salome/examples/h029_regroupMeshesNonEnglobant.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() @@ -60,7 +60,7 @@ fitShapePointsToMesh(os.path.join(tmpdir, "garonneAmont_brd_FreeBorders.shp"), os.path.join(tmpdir, 'raccord_4_1_adj.shp'), tmpdir, False, False) - + # TODO: if limites_amont imported as spline, problem on mesh with 2D triangle algorithm #limites_amont = importPolylines(hydro_doc, os.path.join(tmpdir, "garonneAmont_brd_FreeBorders.shp"), 'garonneAmont_brd_FreeBorders', True, 5) limites_amont = importPolylines(hydro_doc, os.path.join(tmpdir, "garonneAmont_brd_FreeBorders.shp"), 'garonneAmont_brd_FreeBorders', False, 5) diff --git a/doc/salome/examples/h030_editNonHydroMesh.py b/doc/salome/examples/h030_editNonHydroMesh.py index 3d611e7e..1acfb9ab 100644 --- a/doc/salome/examples/h030_editNonHydroMesh.py +++ b/doc/salome/examples/h030_editNonHydroMesh.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") import tempfile tmpdir = tempfile.mkdtemp() diff --git a/doc/salome/examples/h032_completeCaseNoRegions.py b/doc/salome/examples/h032_completeCaseNoRegions.py index 5e5257d0..5b4858c5 100644 --- a/doc/salome/examples/h032_completeCaseNoRegions.py +++ b/doc/salome/examples/h032_completeCaseNoRegions.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") if not os.path.isdir(HYDRO_TEST_RESOURCES): os.mkdir(HYDRO_TEST_RESOURCES) diff --git a/doc/salome/examples/h033_completeCaseModifiedRegions.py b/doc/salome/examples/h033_completeCaseModifiedRegions.py index 651f9cb4..89083975 100644 --- a/doc/salome/examples/h033_completeCaseModifiedRegions.py +++ b/doc/salome/examples/h033_completeCaseModifiedRegions.py @@ -2,7 +2,7 @@ import os HYDRO_SAMPLES = os.path.join( os.environ["HYDRO_ROOT_DIR"], "bin/salome/test/HYDRO") -HYDRO_TEST_RESOURCES = "/home/paul/testsHydro" #os.environ("HYDRO_TEST_RESOURCES") +HYDRO_TEST_RESOURCES = os.path.join(os.environ["HYDRO_DIR"], "bin", "salome", "test", "tmp_test") if not os.path.isdir(HYDRO_TEST_RESOURCES): os.mkdir(HYDRO_TEST_RESOURCES)