]> SALOME platform Git repositories - modules/paravis.git/commitdiff
Salome HOME
Fix of failed tests.
authorakl <akl@opencascade.com>
Fri, 16 May 2014 05:18:19 +0000 (09:18 +0400)
committerakl <akl@opencascade.com>
Fri, 16 May 2014 05:18:19 +0000 (09:18 +0400)
test/VisuPrs/Util/paravistest.py
test/VisuPrs/bugs/A6.py
test/VisuPrs/imps/A1.py

index f63f3ea4fde79b5edeeffbc1e9f6c1eb5e31e35f..a3569df3ba4206aa312d2687feaf43b6348b485d 100755 (executable)
@@ -241,26 +241,21 @@ def TimeStampId(proxy):
     Originally defined in KERNEL_TEST/Tools/CommonFunctions file.
     """
     import presentations
-    mesh_name = presentations.get_mesh_names(proxy).pop()
+    mesh_name = presentations.get_mesh_full_names(proxy).pop()
     iterations = {}
 
     # get list of field names
-    fields_on_points = list(proxy.PointArrays)
-    fields_on_cells = list(proxy.CellArrays)
-    all_fields = fields_on_points + fields_on_cells
+    all_fields = proxy.GetProperty("FieldsTreeInfo")[::2]
 
     # get timestamps
     timestamps = proxy.TimestepValues.GetData()
     timestamp_nb = len(timestamps)
 
     for field in all_fields:
-        entity = None
-        if fields_on_points.count(field) > 0:
-            entity = presentations.EntityType.NODE
-        elif fields_on_cells.count(field) > 0:
-            entity = presentations.EntityType.CELL
-            
-        iterations[field] = [entity, timestamp_nb]
+        entity = presentations.get_field_entity(field)
+        field_short_name = presentations.get_field_short_name(field)
+
+        iterations[field_short_name] = [entity, timestamp_nb]
 
     return mesh_name, iterations
     
index 9d42a52315964e14a09f08076e843e4948103d7e..ee43def87ae5de81917059bd24560155593b2771 100644 (file)
@@ -43,8 +43,8 @@ else:
     print "OK"
 
 # 2. Create mesh
-mesh_names = get_mesh_names(med_reader)
-for mesh_name in mesh_names:
+mesh_names = get_mesh_full_names(med_reader)
+for mesh_name in [get_field_short_name(name) for name in mesh_names]:
     print "Mesh name: ", mesh_name
     mesh = MeshOnEntity(med_reader, mesh_name, EntityType.CELL)
     if mesh is None:
index ed69077ce84034440d90a15ec136c5f512b8099b..1bf50334a20e1aab9189d13dee7d5359c7db7c2c 100644 (file)
@@ -80,7 +80,7 @@ select_cells_with_data(med_reader, on_cells=["scalar field", "vectoriel field"])
 
 print "Setting of deformation:"
 warp_vector = pvsimple.WarpByVector(cutplanes.Input)
-warp_vector.Vectors = ["vectoriel field"]
+warp_vector.Vectors = ["scalar field"]
 warp_vector.ScaleFactor = 5.0
 
 print "Got scale     : ", warp_vector.ScaleFactor