EXPORT_PYSCRIPTS = libVISU_Swig.py batchmode_visu.py batchmode_visu_table.py batchmode_visu_view3d.py \
visu_med.py visu_view3d.py visu.py visu_gui.py visu_prs_example.py\
visu_table.py visu_big_table.py visu_view.py \
- visu_swig_test.py test_events.py
+ visu_swig_test.py test_events.py batch_test_events.py
EXPORT_SHAREDPYSCRIPTS = VISU_shared_modules.py
LIB_CLIENT_IDL =
--- /dev/null
+###############################################################
+#
+# File : batch_test_events.py
+# Description : Test postEvent() functionality for VISU module
+#
+###############################################################
+
+import batchmode_visu
+
+for i in range ( 10 ):
+ batchmode_visu.myVisu.CreateTestView()
+ for j in range ( 10 ):
+ batchmode_visu.myVisu.ShowTestObject();
+
#
# File : test_events.py
# Description : Test postEvent() functionality for VISU module
-#
+# This script can be run from GUI Python console only!
###############################################################
-import batchmode_visu
+import salome
+
+# it's necessary to load VISU engine, this will cause VisuGUI to be loaded
+salome.lcc.FindOrLoadComponent("FactoryServer","VISU")
+
+# this can be done only after VISU engine has been loaded
+from libVISU_Swig import *
+
+visu=VISU_Swig()
for i in range ( 10 ):
- batchmode_visu.myVisu.CreateTestView()
+ visu.CreateTestView()
for j in range ( 10 ):
- batchmode_visu.myVisu.ShowTestObject();
+ visu.ShowTestObject();