X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPlugins%2FMEDReader%2FTest%2FtestMEDReader1.py;h=cbee37b9fafa94056ba261106995f32e226dcd2a;hb=94cbfad1aa9258373e9eba509a607e87e78dfb7d;hp=bede0eb8ac1e8d81690b91275549e37ddccac685;hpb=9dbade0021c7a8e21aedcfb28be257886abed924;p=modules%2Fparavis.git diff --git a/src/Plugins/MEDReader/Test/testMEDReader1.py b/src/Plugins/MEDReader/Test/testMEDReader1.py index bede0eb8..cbee37b9 100644 --- a/src/Plugins/MEDReader/Test/testMEDReader1.py +++ b/src/Plugins/MEDReader/Test/testMEDReader1.py @@ -1,10 +1,10 @@ # -*- coding: iso-8859-1 -*- -# Copyright (C) 2007-2014 CEA/DEN, EDF R&D +# Copyright (C) 2007-2016 CEA/DEN, EDF R&D # # This library is free software; you can redistribute it and/or # modify it under the terms of the GNU Lesser General Public # License as published by the Free Software Foundation; either -# version 2.1 of the License. +# version 2.1 of the License, or (at your option) any later version. # # This library is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -22,11 +22,10 @@ from MEDLoader import * """ -This test focused on ELNO. Here a 2 QUAD4 cells and a single ELNO field +This test focused on ELNO. Here a 2 QUAD4 cells and a single ELNO field is defined. """ fname="testMEDReader1.med" -outImgName="testMEDReader1.png" coords=DataArrayDouble([(0,0,0),(2,1,0),(1,0,0),(1,1,0),(2,0,0),(0,1,0)]) m=MEDCouplingUMesh("mesh",2) ; m.setCoords(coords) @@ -34,26 +33,26 @@ m.allocateCells() m.insertNextCell(NORM_QUAD4,[0,5,3,2]) m.insertNextCell(NORM_QUAD4,[4,2,3,1]) m.finishInsertingCells() -MEDLoader.WriteMesh(fname,m,True) +WriteMesh(fname,m,True) # f0=MEDCouplingFieldDouble(ON_GAUSS_NE) ; f0.setMesh(m) ; f0.setTimeUnit("ms") f0.setTime(1.1,1,1) f0.setName("myELNOField") arr=DataArrayDouble([7,5,3,1,5,3,1,7]) ; arr.setInfoOnComponent(0,"Comp0") f0.setArray(arr) -MEDLoader.WriteFieldUsingAlreadyWrittenMesh(fname,f0) +WriteFieldUsingAlreadyWrittenMesh(fname,f0) # f0.setTime(2.2,2,1) arr=DataArrayDouble([1,7,5,3,7,5,3,1]) ; arr.setInfoOnComponent(0,"Comp0") f0.setArray(arr) -MEDLoader.WriteFieldUsingAlreadyWrittenMesh(fname,f0) +WriteFieldUsingAlreadyWrittenMesh(fname,f0) # f0.setTime(3.3,3,1) arr=DataArrayDouble([3,1,7,5,1,7,5,3]) ; arr.setInfoOnComponent(0,"Comp0") f0.setArray(arr) -MEDLoader.WriteFieldUsingAlreadyWrittenMesh(fname,f0) +WriteFieldUsingAlreadyWrittenMesh(fname,f0) # f0.setTime(4.4,4,1) arr=DataArrayDouble([5,3,1,7,3,1,7,5]) ; arr.setInfoOnComponent(0,"Comp0") f0.setArray(arr) -MEDLoader.WriteFieldUsingAlreadyWrittenMesh(fname,f0) +WriteFieldUsingAlreadyWrittenMesh(fname,f0)