theStudy = salome.myStudy
from HYDROPy import *
-from PyQt4.QtCore import *
-from PyQt4.QtGui import *
+from PyQt5.QtCore import *
+from PyQt5.QtGui import *
hydro_doc = HYDROData_Document.Document( theStudy._get_StudyId() )
Cloud_inexistant.SetName( "Cloud_inexistant" )
Cloud_inexistant.SetAltitudesInverted( 0 );
-Cloud_inexistant.ImportFromFile( os.path.join(HYDRO_SAMPLES, "Cloud_inexistant.xyz" ))
+ret = Cloud_inexistant.ImportFromFile( os.path.join(HYDRO_SAMPLES, "Cloud_inexistant.xyz" ))
-# TODO : ce chargement doit echouer avec un retour d'erreur à traiter
-raise ValueError('file not found')
-
-Cloud_inexistant.Update()
+if ret:
+ raise ValueError('loading problem not detected: return value should be null')
if salome.sg.hasDesktop():
salome.sg.updateObjBrowser(1)