Пример #1
0
#/usr/bin/env python

import QtTesting
import QtTestingImage
import time

object1 = 'MainWindow/mainToolBar/1QToolButton0'
QtTesting.playCommand(object1, 'activate', '')
object3 = 'MainWindow/FileOpenDialog'
QtTesting.playCommand(object3, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/dualSphereAnimation.pvd')
object4 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/Accept'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'MainWindow/VCRToolbar/1QToolButton2'
QtTesting.playCommand(object5, 'activate', '')

while QtTesting.getProperty(object5, 'text') != 'Play':
    time.sleep(0.2)

snapshotWidget = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'VCRAnimation.png', 300, 300)
Пример #2
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menu_File'
QtTesting.playCommand(object1, 'activate', 'actionFileOpen')
object2 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object2, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/FileSeries/blow..vtk')
object12 = 'pqClientMainWindow/currentTimeToolbar/CurrentTimeIndex'
QtTesting.playCommand(object12, 'set_int', '0')
QtTesting.playCommand(object12, 'key', '16777220')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object3, 'activate', '')
object4 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTesting.playCommand(object4, 'mousePress', '(0.539658,0.641618,1,1,0)')
QtTesting.playCommand(object4, 'mouseMove', '(0.225505,0.603083,1,0,0)')
QtTesting.playCommand(object4, 'mouseRelease', '(0.225505,0.603083,1,0,0)')
object5 = 'pqClientMainWindow/axesToolbar/1QToolButton0'
QtTesting.playCommand(object5, 'set_boolean', 'false')
object6 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object6, 'set_string', 'cellNormals')
QtTesting.playCommand(object6, 'set_string', 'thickness')
object7 = 'pqClientMainWindow/menubar/menuFilters/pqProxyGroupMenuManager0/WarpVector'
QtTesting.playCommand(object7, 'activate', '')
QtTesting.playCommand(object3, 'activate', '')
#object8 = 'pqClientMainWindow/menubar/menuTools'
#QtTesting.playCommand(object8, 'activate', 'actionToolsRecordTestScreenshot')
#object9 = 'pqClientMainWindow/RecordTestScreenshotDialog'
#QtTesting.playCommand(object9, 'filesSelected', '$PARAVIEW_DATA_ROOT/Baseline/FileSeries1.png')
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
Пример #3
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'MainWindow/menubar/menuFile'
QtTesting.playCommand(object1, 'activate', 'actionFileLoadServerState')
object2 = 'MainWindow/ServerStartupBrowser/connect'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'MainWindow/FileLoadServerStateDialog'
QtTesting.playCommand(object3, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/LoadStateHistogram.pvsm')
object4 = 'MainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView'
QtTesting.playCommand(object4, 'currentChanged', '/0/0/0|0')
object5 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QTabBar0'
QtTesting.playCommand(object5, 'set_tab', '1')
QtTesting.playCommand(object5, 'set_tab', '0')
object6 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/BinCount'
QtTesting.playCommand(object6, 'set_string', '1')
QtTesting.playCommand(object6, 'set_string', '16')
object7 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/Accept'
QtTesting.playCommand(object7, 'activate', '')

object8 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/PlotWidget'
QtTestingImage.compareImage(object8, 'HistogramChart.png', 400, 200)
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menuFile'
QtTesting.playCommand(object1, 'activate', 'actionFileLoadServerState')
object2 = 'pqClientMainWindow/ServerStartupBrowser/connect'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/FileLoadServerStateDialog'
QtTesting.playCommand(object3, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/LoadStateHistogram.pvsm')
object4 = 'pqClientMainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView'
QtTesting.playCommand(object4, 'currentChanged', '/0/0/0|0')
object5 = 'pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/1QTabBar0'
QtTesting.playCommand(object5, 'set_tab', '1')
QtTesting.playCommand(object5, 'set_tab', '0')
object6 = 'pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/BinCount'
QtTesting.playCommand(object6, 'set_string', '1')
QtTesting.playCommand(object6, 'set_string', '16')
object7 = 'pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/Accept'
QtTesting.playCommand(object7, 'activate', '')

object8 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/PlotWidget'
QtTestingImage.compareImage(object8, 'HistogramChart.png', 400, 200)

Пример #5
0
  object1013 = 'pqClientMainWindow/SaveSnapshotDialog/ok'
  QtTesting.playCommand(object1013, 'activate', '')
  object1014 = 'pqClientMainWindow/FileSaveScreenshotDialog'
  QtTesting.playCommand(object1014, 'remove',
                        '$PARAVIEW_TEST_ROOT/'+name)
  QtTesting.playCommand(object1014, 'filesSelected', '$PARAVIEW_TEST_ROOT/'+name)
  QtTesting.playCommand(object1008, 'pause', '2000')
  QtTestingImage.compareImage('$PARAVIEW_TEST_ROOT/'+name, name);

#using this to put 'barriers' in to deal with streaming and testing asynchrony
object1008 = 'pqClientMainWindow'

#load streaming view plugin on client and server sides
print "loading plugin"
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuTools')
object2 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object2, 'activate', 'actionManage_Plugins')
object3 = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(object3, 'setCurrent', 'MantaView')
QtTesting.playCommand(object3, 'setCurrent', 'StreamingView')
object4 = 'pqClientMainWindow/PluginManagerDialog/localGroup'
QtTesting.playCommand(object4, 'mousePress', '1,1,0,152,504')
QtTesting.playCommand(object4, 'mouseRelease', '1,0,0,152,504')
object5 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'pqClientMainWindow/PluginManagerDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object6, 'activate', '')

# Test the iterating view by rendering the first 7 pieces
print "opening iterating view"
Пример #6
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object1, 'activate', '')
object2 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object2, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/SPCTH/Dave_Karelitz_Small/spcth_a')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/CellArrayStatus/1QHeaderView0'
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
object4 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/representationToolbar/displayRepresentation/comboBox'
QtTesting.playCommand(object5, 'set_string', 'Surface')
object6 = 'pqClientMainWindow/cameraToolbar/actionNegativeY'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object7, 'set_string', 'Pressure (dynes/cm^2^)')
object8 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object8, 'activate', 'menuFilters')
object9 = 'pqClientMainWindow/menubar/menuFilters/Alphabetical'
QtTesting.playCommand(object9, 'activate', 'AMRDualContour')
object10 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/SelectMaterialArrays/1QHeaderView0'
QtTesting.playCommand(object10, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object10, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object7, 'set_string',
                      'Pressure (dynes/cm^2^) (partial)')
Пример #7
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menu_File'
QtTesting.playCommand(object1, 'activate', 'actionFileLoadServerState')
##object2 = 'pqClientMainWindow/ServerStartupBrowser/connect'
#QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/FileLoadServerStateDialog'
QtTesting.playCommand(object3, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/LoadStateMultiView.pvsm')
object4 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/MaximizeButton'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/centralwidget/MultiViewManager/MaximizeFrame/0/MultiViewFrameMenu/RestoreButton'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object8, 'activate', '')
object9 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalButton'
QtTesting.playCommand(object9, 'activate', '')
object10 = 'pqClientMainWindow/pipelineBrowserDock/pipelineBrowser'
QtTesting.playCommand(object10, 'currentChanged', '/0/2|0')
#QtTesting.playCommand(object10, 'currentChanged', '/0/2|1')
object11 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_tabbar'
QtTesting.playCommand(object11, 'set_tab', '1')
QtTesting.playCommand(object1, 'activate', 'actionFileSaveServerState')
object13 = 'pqClientMainWindow/FileSaveServerStateDialog'
Пример #8
0
# /usr/bin/env python

import QtTesting
import QtTestingImage

#############################################################################
# Load the SLAC pic-example data and fields.

object2 = "pqClientMainWindow/MainControlsToolbar/actionOpenData"
QtTesting.playCommand(object2, "activate", "")
object3 = "pqClientMainWindow/FileOpenDialog"
QtTesting.playCommand(object3, "filesSelected", "$PARAVIEW_DATA_ROOT/Data/SLAC/pic-example/mesh.ncdf")
object4 = "pqClientMainWindow/pqSelectReaderDialog/listWidget"
QtTesting.playCommand(object4, "currentChangedbyItemName", "SLAC Mesh Files")
object5 = "pqClientMainWindow/pqSelectReaderDialog/okButton"
QtTesting.playCommand(object5, "activate", "")
object6 = "pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ModeFileName/FileButton"
QtTesting.playCommand(object6, "activate", "")
object7 = "pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ModeFileName/pqFileDialog"
QtTesting.playCommand(object7, "filesSelected", "$PARAVIEW_DATA_ROOT/Data/SLAC/pic-example/fields_..mod")
object8 = "pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept"
QtTesting.playCommand(object8, "activate", "")
QtTesting.playCommand(object8, "activate", "")
object9 = "pqClientMainWindow/variableToolbar/displayColor/Variables"
QtTesting.playCommand(object9, "set_string", "efield")

# Image compare for default colors.
snapshotWidget = "pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport"
QtTestingImage.compareImage(snapshotWidget, "RenderNanDefaultColor.png", 300, 300)

#############################################################################
Пример #9
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

#----------------- NEXT TEST -----------
# Test isovolume of point data for vtkImageData.
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuSources')
object2 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object2, 'activate', 'RTAnalyticSource')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object3, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'menuFilters')
object4 = 'pqClientMainWindow/menubar/menuFilters/Alphabetical'
QtTesting.playCommand(object4, 'activate', 'IsoVolume')
object5 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ThresholdBetween_0/LineEdit'
object6 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ThresholdBetween_1/LineEdit'
QtTesting.playCommand(object6, 'set_string', '150')
QtTesting.playCommand(object5, 'set_string', '140')
QtTesting.playCommand(object3, 'activate', '')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'TestIsoVolume1.png', 300, 300)

#----------------- NEXT TEST -----------
# Test isovolume of cell data for vtkImageData.

object7 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Delete'
QtTesting.playCommand(object7, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'menuFilters')
#/usr/bin/env python

import QtTesting
import time

object1 = 'pqClientMainWindow/menubar/menuHelp'
QtTesting.playCommand(object1, 'activate', 'actionHelpHelp')

# since this starts a new process, we'll wait for a bit
# before finishing the test, to give the other process
# time to report an error condition
time.sleep(5)

#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'RTAnalyticSource')
object2 = 'pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalButton'
QtTesting.playCommand(object3, 'activate', '')
object4 = 'pqClientMainWindow/menubar/menuFilters/DataAnalysis'
QtTesting.playCommand(object4, 'activate', 'ProbeLine')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'pqClientMainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView'
QtTesting.playCommand(object6, 'mousePress', '1,1,0,51,13,/0:0/0:0')
QtTesting.playCommand(object6, 'mouseRelease', '1,0,0,51,13,/0:0/0:0')
QtTesting.playCommand(object4, 'activate', 'ExtractHistogram')
QtTesting.playCommand(object2, 'activate', '')
object7 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/WindowCaption'
QtTesting.playCommand(object8, 'mousePress', '1,1,0,42,4')
QtTesting.playCommand(object8, 'mouseRelease', '1,0,0,42,4')

object9 = 'pqClientMainWindow/menubar/menuFile'
QtTesting.playCommand(object9, 'activate', 'actionFileSaveScreenshot')
object12 = 'pqClientMainWindow/SaveSnapshotDialog/selectedViewOnly'
QtTesting.playCommand(object12, 'set_boolean', 'false')
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'SphereSource')
object2 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object3, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'SphereSource')
object4 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/Center_0'
QtTesting.playCommand(object4, 'set_string', '1')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/pipelineBrowserDock/pipelineBrowser'
QtTesting.playCommand(object5, 'currentChanged', '/0/0|0')
object6 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_tabbar'
QtTesting.playCommand(object6, 'set_tab', '1')
object7 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/1QScrollArea0/qt_scrollarea_viewport/1pqDisplayProxyEditorWidget0/Form/ViewGroup/ViewData'
QtTesting.playCommand(object7, 'set_boolean', 'true')
object8 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object8, 'activate', 'menu_View')
object8 = 'pqClientMainWindow/menubar/menu_View'
QtTesting.playCommand(object8, 'activate', 'Animation View')
object9 = 'pqClientMainWindow/animationViewDock/animationView/pqAnimationWidget/CreateDeleteWidget/PropertyCombo'
QtTesting.playCommand(object9, 'set_string', 'Start Theta')
object10 = "pqClientMainWindow/animationViewDock/animationView/1pqAnimationWidget0/1QHeaderView0"
QtTesting.playCommand(object10, "mousePress", "1,1,0,0,0,2")
QtTesting.playCommand(object10, "mouseRelease", "1,1,0,0,0,2")
object11 = 'pqClientMainWindow/VCRToolbar/1QToolButton3'
Пример #13
0
#/usr/bin/env python

import QtTesting
import time

object1 = 'MainWindow/menubar/menuHelp'
QtTesting.playCommand(object1, 'activate', 'actionHelpHelp')

# since this starts a new process, we'll wait for a bit
# before finishing the test, to give the other process
# time to report an error condition
time.sleep(5)

Пример #14
0
# /usr/bin/env python

# Tests manta server side rendering for CS mode
# MantaTest.py tests client side rendering in builtin and CS mode

import QtTesting
import QtTestingImage

# TODO fix test recording so that it actually records these events
# most of which I had to hack in by hand

# force server side rendering by setting threshold to 0
object2 = "pqClientMainWindow/menubar/menu_Edit"
QtTesting.playCommand(object2, "activate", "actionEditSettings")
objectb2 = "pqClientMainWindow/ApplicationSettings/PageNames"
QtTesting.playCommand(objectb2, "setCurrent", "4.0")
QtTesting.playCommand(objectb2, "expand", "4.0")
QtTesting.playCommand(objectb2, "setCurrent", "4.0.2.0")
objectb3 = "pqClientMainWindow/ApplicationSettings/Stack/pqGlobalRenderViewOptions/stackedWidget/Server/compositingParameters/compositeThreshold"
QtTesting.playCommand(objectb3, "set_int", "0")
objectb4 = "pqClientMainWindow/ApplicationSettings/CloseButton"
QtTesting.playCommand(objectb4, "activate", "")

# load manta plugin on client and server sides
hack1 = "pqClientMainWindow/menubar"
QtTesting.playCommand(hack1, "activate", "menuTools")
hack2 = "pqClientMainWindow/menubar/menuTools"
QtTesting.playCommand(hack2, "activate", "actionManage_Plugins")
object1 = "pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins"
QtTesting.playCommand(object1, "setCurrent", "MantaView")
object2 = "pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local"
Пример #15
0
#/usr/bin/env python

import QtTesting
import sys

libname = 'libGUIConePanel.so'
if sys.platform == 'win32':
    libname = 'GUIConePanel.dll'

if sys.platform == 'darwin':
    libname = 'libGUIConePanel.dylib'

object1 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
object2 = 'pqClientMainWindow/pqPluginDialog/localGroup/loadLocal'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
QtTesting.playCommand(object3, 'filesSelected', libname)
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object5, 'activate', 'Cone')
object7 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Accept'
QtTesting.playCommand(object7, 'activate', '')

object8 = 'pqClientMainWindow/objectInspectorDock/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/1QLabel0'

text = QtTesting.getProperty(object8, 'text')
print(text)
Пример #16
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

#----------------- NEXT TEST -----------
# Test isovolume of point data for vtkImageData.
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuSources')
object2 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object2, 'activate', 'RTAnalyticSource')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object3, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'menuFilters')
object4 = 'pqClientMainWindow/menubar/menuFilters/Alphabetical'
QtTesting.playCommand(object4, 'activate', 'IsoVolume')
object5 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ThresholdBetween_0/LineEdit'
object6 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ThresholdBetween_1/LineEdit'
QtTesting.playCommand(object6, 'set_string', '150')
QtTesting.playCommand(object5, 'set_string', '140')
QtTesting.playCommand(object3, 'activate', '')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'TestIsoVolume1.png', 300, 300);

#----------------- NEXT TEST -----------
# Test isovolume of cell data for vtkImageData.

object7 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Delete'
QtTesting.playCommand(object7, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'menuFilters')
Пример #17
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menu_File'
QtTesting.playCommand(object1, 'activate', 'actionFileOpen')
object2 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object2, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/FileSeries/blow..vtk')
object12 = 'pqClientMainWindow/currentTimeToolbar/CurrentTimeIndex'
QtTesting.playCommand(object12, 'set_int', '0')
QtTesting.playCommand(object12, 'key', '16777220')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object3, 'activate', '')
object4 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTesting.playCommand(object4, 'mousePress', '(0.539658,0.641618,1,1,0)')
QtTesting.playCommand(object4, 'mouseMove', '(0.225505,0.603083,1,0,0)')
QtTesting.playCommand(object4, 'mouseRelease', '(0.225505,0.603083,1,0,0)')
object5 = 'pqClientMainWindow/axesToolbar/1QToolButton0'
QtTesting.playCommand(object5, 'set_boolean', 'false')
object6 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object6, 'set_string', 'cellNormals')
QtTesting.playCommand(object6, 'set_string', 'thickness')
object7 = 'pqClientMainWindow/menubar/menuFilters/pqProxyGroupMenuManager0/WarpVector'
QtTesting.playCommand(object7, 'activate', '')
QtTesting.playCommand(object3, 'activate', '')
#object8 = 'pqClientMainWindow/menubar/menuTools'
#QtTesting.playCommand(object8, 'activate', 'actionToolsRecordTestScreenshot')
#object9 = 'pqClientMainWindow/RecordTestScreenshotDialog'
#QtTesting.playCommand(object9, 'filesSelected', '$PARAVIEW_DATA_ROOT/Baseline/FileSeries1.png')
Пример #18
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

#############################################################################
# Load the SLAC pic-example data and fields.

object2 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object3, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/SLAC/pic-example/mesh.ncdf')
object4 = 'pqClientMainWindow/pqSelectReaderDialog/listWidget'
QtTesting.playCommand(object4, 'currentChangedbyItemName', 'SLAC Mesh Files')
object5 = 'pqClientMainWindow/pqSelectReaderDialog/okButton'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ModeFileName/FileButton'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/ModeFileName/pqFileDialog'
QtTesting.playCommand(
    object7, 'filesSelected',
    '$PARAVIEW_DATA_ROOT/Data/SLAC/pic-example/fields_..mod')
object8 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object8, 'activate', '')
QtTesting.playCommand(object8, 'activate', '')
object9 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object9, 'set_string', 'efield')

# Image compare for default colors.
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
    QtTesting.playCommand(object1013, 'activate', '')
    object1014 = 'pqClientMainWindow/FileSaveScreenshotDialog'
    QtTesting.playCommand(object1014, 'remove', '$PARAVIEW_TEST_ROOT/' + name)
    QtTesting.playCommand(object1014, 'filesSelected',
                          '$PARAVIEW_TEST_ROOT/' + name)
    QtTesting.playCommand(object1008, 'pause', '2000')
    QtTestingImage.compareImage('$PARAVIEW_TEST_ROOT/' + name, name)


#using this to put 'barriers' in to deal with streaming and testing asynchrony
object1008 = 'pqClientMainWindow'

#load streaming view plugin on client and server sides
print "loading plugin"
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuTools')
object2 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object2, 'activate', 'actionManage_Plugins')
object3 = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(object3, 'setCurrent', 'StreamingView')
object4 = 'pqClientMainWindow/PluginManagerDialog/localGroup'
QtTesting.playCommand(object4, 'mousePress', '1,1,0,152,504')
QtTesting.playCommand(object4, 'mouseRelease', '1,0,0,152,504')
object5 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
QtTesting.playCommand(object5, 'activate', '')
objectR1 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/remotePlugins'
QtTesting.playCommand(objectR1, 'setCurrent', 'StreamingView')
objectR2 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/loadSelected_Remote'
QtTesting.playCommand(objectR2, 'activate', '')
object6 = 'pqClientMainWindow/PluginManagerDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object6, 'activate', '')
Пример #20
0
#/usr/bin/env python

import QtTesting
import sys

libname = 'libStreamingPlugin.so'
if sys.platform == 'win32':
    libname = 'StreamingPlugin.dll'
if sys.platform == 'darwin':
    libname = 'libStreamingPlugin.dylib'

object1 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
object2 = "pqClientMainWindow/pqPluginDialog/localGroup/loadLocal"
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
QtTesting.playCommand(object3, 'filesSelected', libname)
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object4, 'activate', '')
object6 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/1QWidget0/1QScrollArea0/qt_scrollarea_viewport/EmptyView/ConvertActionsFrame/1QPushButton0'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object8, 'activate', 'actionTesting_Window_Size')

object9 = 'pqClientMainWindow/menubar/menuFile'
QtTesting.playCommand(object9, 'activate', 'actionFileOpen')
object9a = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object9a, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/noisy_10x100x100_sphere.raw')
Пример #21
0
#/usr/bin/env python

#Tests manta server side rendering for CS mode
#MantaTest.py tests client side rendering in builtin and CS mode

import QtTesting
import QtTestingImage

#TODO fix test recording so that it actually records these events
#most of which I had to hack in by hand

#force server side rendering by setting threshold to 0
object2 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object2, 'activate', 'actionEditSettings')
objectb2 = 'pqClientMainWindow/ApplicationSettings/PageNames'
QtTesting.playCommand(objectb2, 'setCurrent', '4.0')
QtTesting.playCommand(objectb2, 'expand', '4.0')
QtTesting.playCommand(objectb2, 'setCurrent', '4.0.2.0')
objectb3 = 'pqClientMainWindow/ApplicationSettings/Stack/pqGlobalRenderViewOptions/stackedWidget/Server/compositingParameters/compositeThreshold'
QtTesting.playCommand(objectb3, 'set_int', '0')
objectb4 = 'pqClientMainWindow/ApplicationSettings/CloseButton'
QtTesting.playCommand(objectb4, 'activate', '')

#load manta plugin on client and server sides
hack1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(hack1, 'activate', 'menuTools')
hack2 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(hack2, 'activate', 'actionManage_Plugins')
object1 = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(object1, 'setCurrent', 'MantaView')
object2 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
object1 = 'pqClientMainWindow/menubar/menuTools'
object2 = 'pqClientMainWindow/pqPluginDialog/localGroup/loadLocal'
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
object5 = 'pqClientMainWindow/pqFileDialog'
object6 = 'pqClientMainWindow/pqBlotDialog/buttons/runScript'
object7 = 'pqClientMainWindow/pqBlotDialog/BLOTShellRunScriptDialog'
object8 = 'pqClientMainWindow/pqBlotDialog/buttons/close'

testDir = QtTesting.getProperty('pqClientMainWindow', 'TestDirectory')

blotTestFile = "%s/PVBlotTest1.bl" % testDir

blotFile = open(blotTestFile, 'w')
blotFile.write(blotScriptBody)
blotFile.close()

QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.playCommand(object3, 'filesSelected', pluginFile)
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'PVBlot')
QtTesting.playCommand(object5, 'filesSelected', dataFile)
QtTesting.playCommand(object6, 'activate', '')
QtTesting.playCommand(object7, 'filesSelected', blotTestFile)
QtTesting.playCommand(object8, 'activate', '')

import time
time.sleep(10)
Пример #23
0
#/usr/bin/env python

import QtTesting
import sys

libname = 'libGUIConePanel.so'
if sys.platform == 'win32':
    libname = 'GUIConePanel.dll'

if sys.platform == 'darwin':
    libname = 'libGUIConePanel.dylib'

object1 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
object2 = 'pqClientMainWindow/pqPluginDialog/localGroup/loadLocal'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
QtTesting.playCommand(object3, 'filesSelected', libname)
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object5, 'activate', 'Cone')
object7 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object7, 'activate', '')

object8 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/1QLabel0'

text = QtTesting.getProperty(object8, 'text')
print text

Пример #24
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

# Always render on server.  Nonlinear wireframes do not work when delivering to client (bug #10676).
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menu_Edit')
object2 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object2, 'activate', 'actionEditSettings')
object3 = 'pqClientMainWindow/ApplicationSettings/PageNames'
QtTesting.playCommand(object3, 'expand', '4.0')
QtTesting.playCommand(object3, 'setCurrent', '4.0.2.0')
object4 = 'pqClientMainWindow/ApplicationSettings/Stack/pqGlobalRenderViewOptions/stackedWidget/Server/compositingParameters/compositeThreshold'
QtTesting.playCommand(object4, 'set_int', '0')
object5 = 'pqClientMainWindow/ApplicationSettings/CloseButton'
QtTesting.playCommand(object5, 'activate', '')

# Load the file.
object6 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object7, 'filesSelected',
                      '$PARAVIEW_DATA_ROOT/Data/quadraticTetra01.vtu')
object8 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object8, 'activate', '')

# Edit the color map to capture negative values that occur in the nonlinear interpolation.
#object9 = 'pqClientMainWindow/variableToolbar/actionEditColorMap'
#QtTesting.playCommand(object9, 'activate', '')
#object10 = 'pqClientMainWindow/pqColorScaleDialog/ColorTabs/qt_tabwidget_stackedwidget/ScalePage/UseAutoRescale'
Пример #25
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

QtTesting.playCommand(object1, 'activate', '')
QtTesting.playCommand(object2, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/SPCTH/Dave_Karelitz_Small/spcth_a')
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object5, 'set_string', 'Surface')
QtTesting.playCommand(object6, 'activate', '')
QtTesting.playCommand(object7, 'set_string', 'Pressure (dynes/cm^2^)')
QtTesting.playCommand(object8, 'activate', 'menuFilters')
QtTesting.playCommand(object9, 'activate', 'AMRDualClip')
QtTesting.playCommand(object10, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object10, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object7, 'set_string', 'Pressure (dynes/cm^2^) (partial)')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'CTHAMRDualClip.png', 300, 300)
Пример #26
0
    QtTesting.playCommand(fdUp, 'activate', '')
    QtTesting.playCommand(fdCancel, 'activate', '')
    QtTesting.playCommand(mode, 'set_string', 'Existing Files')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
    QtTesting.playCommand(fdName, 'set_string', 'Filec')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filec.png')
    QtTesting.playCommand(fdOk, 'activate', '')
    checkFile('Filec.png')
    QtTesting.playCommand(mode, 'set_string', 'Existing File')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filea')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(filter, 'set_string', 'Images (*.png;*.bmp)')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/7|0')
    QtTesting.playCommand(fdOk, 'activate', '')
    checkFile('Filec.bmp')


QtTesting.playCommand(connection, 'set_string', 'Local')
runTests()
QtTesting.playCommand(connection, 'set_string', 'Remote')
runTests()
Пример #27
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'RTAnalyticSource')
object2 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalButton'
QtTesting.playCommand(object3, 'activate', '')
object4 = 'pqClientMainWindow/menubar/menuFilters/DataAnalysis'
QtTesting.playCommand(object4, 'activate', 'ProbeLine')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'pqClientMainWindow/pipelineBrowserDock/pipelineBrowser'
QtTesting.playCommand(object6, 'mousePress', '1,1,0,51,13,/0:0/0:0')
QtTesting.playCommand(object6, 'mouseRelease', '1,0,0,51,13,/0:0/0:0')
QtTesting.playCommand(object4, 'activate', 'ExtractHistogram')
QtTesting.playCommand(object2, 'activate', '')
object7 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/WindowCaption'
QtTesting.playCommand(object8, 'mousePress', '1,1,0,42,4')
QtTesting.playCommand(object8, 'mouseRelease', '1,0,0,42,4')

object9 = 'pqClientMainWindow/menubar/menu_File'
QtTesting.playCommand(object9, 'activate', 'actionFileSaveScreenshot')
object12 = 'pqClientMainWindow/SaveSnapshotDialog/selectedViewOnly'
QtTesting.playCommand(object12, 'set_boolean', 'false')
Пример #28
0
def runTests():
    #  initialize
    QtTesting.playCommand(filter, 'set_string', '')
    QtTesting.playCommand(mode, 'set_string', 'Any File')
    #
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdCancel, 'activate', '')
    QtTesting.playCommand(filter, 'set_string', 'File[12].?n?')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdMsgOk, 'activate', '')
    checkFile('Filea.png')
    QtTesting.playCommand(filter, 'set_string', '*.png')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/1|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/2|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/3|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/4|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdMsgOk, 'activate', '')
    checkFile('Filec.png')
    QtTesting.playCommand(mode, 'set_string', 'Existing File')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/4|0')
    QtTesting.playCommand(fdOk, 'activate', '')
    checkFile('Fileb.png')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/2|0')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdUp, 'activate', '')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdUp, 'activate', '')
    QtTesting.playCommand(fdCancel, 'activate', '')
    QtTesting.playCommand(mode, 'set_string', 'Existing Files')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
    QtTesting.playCommand(fdName, 'set_string', 'Filec')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filec.png')
    QtTesting.playCommand(fdOk, 'activate', '')
    checkFile('Filec.png')
    QtTesting.playCommand(mode, 'set_string', 'Existing File')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filea')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
    QtTesting.playCommand(fdOk, 'activate', '')
    QtTesting.playCommand(filter, 'set_string', 'Images (*.png;*.bmp)')
    QtTesting.playCommand(openDialog, 'activate', '')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
    QtTesting.playCommand(fdFiles, 'currentChanged', '/7|0')
    QtTesting.playCommand(fdOk, 'activate', '')
    checkFile('Filec.bmp')
Пример #29
0
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
object5 = 'pqClientMainWindow/pqFileDialog'
object6 = 'pqClientMainWindow/pqBlotDialog/buttons/runScript'
object7 = 'pqClientMainWindow/pqBlotDialog/BLOTShellRunScriptDialog'
object8 = 'pqClientMainWindow/pqBlotDialog/buttons/close'


testDir = QtTesting.getProperty('pqClientMainWindow', 'TestDirectory')


blotTestFile = "%s/PVBlotTest1.bl" % testDir

blotFile = open(blotTestFile, 'w')
blotFile.write(blotScriptBody)
blotFile.close()

QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.playCommand(object3, 'filesSelected', pluginFile)
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'PVBlot')
QtTesting.playCommand(object5, 'filesSelected', dataFile)
QtTesting.playCommand(object6, 'activate', '')
QtTesting.playCommand(object7, 'filesSelected', blotTestFile)
QtTesting.playCommand(object8, 'activate', '')

import time
time.sleep(10)

Пример #30
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object1, 'activate', '')
object2 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object2, 'filesSelected', '$PARAVIEW_DATA_ROOT/SPCTH/Dave_Karelitz_Small/spcth_a')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/CellArrayStatus/1QHeaderView0'
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
object4 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/representationToolbar/displayRepresentation/comboBox'
QtTesting.playCommand(object5, 'set_string', 'Surface')
object6 = 'pqClientMainWindow/cameraToolbar/actionNegativeY'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object7, 'set_string', 'Pressure (dynes/cm^2^)')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'CTHAMRBaseline.png', 300, 300)


Пример #31
0
# /usr/bin/env python

import QtTesting
import QtTestingImage

object1 = "pqClientMainWindow/menubar/menuSources"
QtTesting.playCommand(object1, "activate", "SphereSource")
object2 = "pqClientMainWindow/objectInspectorDock/objectInspector/Accept"
QtTesting.playCommand(object2, "activate", "")
object3 = "pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/SplitVertical"
QtTesting.playCommand(object3, "activate", "")
QtTesting.playCommand(object1, "activate", "SphereSource")
object4 = (
    "pqClientMainWindow/objectInspectorDock/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/Center_0"
)
QtTesting.playCommand(object4, "set_string", "1")
QtTesting.playCommand(object2, "activate", "")
object5 = "pqClientMainWindow/pipelineBrowserDock/pipelineBrowser"
QtTesting.playCommand(object5, "currentChanged", "/0/0|0")
object6 = "pqClientMainWindow/1QTabBar1"
QtTesting.playCommand(object6, "set_tab_with_text", "Display")
object7 = "pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/Form/ViewGroup/ViewData"
QtTesting.playCommand(object7, "set_boolean", "true")
object8 = "pqClientMainWindow/menubar"
QtTesting.playCommand(object8, "activate", "menu_View")
object8 = "pqClientMainWindow/menubar/menu_View"
QtTesting.playCommand(object8, "activate", "Animation View")
object9 = "pqClientMainWindow/animationViewDock/animationView/pqAnimationWidget/CreateDeleteWidget/PropertyCombo"
QtTesting.playCommand(object9, "set_string", "Start Theta")
object10 = "pqClientMainWindow/animationViewDock/animationView/1pqAnimationWidget0/1QHeaderView0"
QtTesting.playCommand(object10, "mousePress", "1,1,0,0,0,2")
Пример #32
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'MainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'SphereSource')
object2 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object3, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'SphereSource')
object4 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/Center_0'
QtTesting.playCommand(object4, 'set_string', '1')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'MainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView'
QtTesting.playCommand(object5, 'currentChanged', '/0/0|0')
object6 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_tabbar'
QtTesting.playCommand(object6, 'set_tab', '1')
object7 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/1QScrollArea0/qt_scrollarea_viewport/1pqDisplayProxyEditorWidget0/Form/ViewGroup/ViewData'
QtTesting.playCommand(object7, 'set_boolean', 'true')
object8 = 'MainWindow/menubar/menuView'
QtTesting.playCommand(object8, 'activate', 'Animation Inspector')
object9 = 'MainWindow/animationPanelDock/1pqAnimationPanel0/scrollArea/qt_scrollarea_viewport/AnimationPanel/tracksGroup/propertyName'
QtTesting.playCommand(object9, 'set_string', 'Start Theta')
object10 = 'MainWindow/animationPanelDock/1pqAnimationPanel0/scrollArea/qt_scrollarea_viewport/AnimationPanel/keyFramePropertiesGroup/addKeyFrame'
QtTesting.playCommand(object10, 'activate', '')
object11 = 'MainWindow/VCRToolbar/1QToolButton3'
QtTesting.playCommand(object11, 'activate', '')
QtTesting.playCommand(object11, 'activate', '')
object12 = 'MainWindow/menubar/menuFile'
Пример #33
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

QtTesting.playCommand(object1, 'activate', '')
QtTesting.playCommand(
    object2, 'filesSelected',
    '$PARAVIEW_DATA_ROOT/Data/SPCTH/Dave_Karelitz_Small/spcth_a')
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseMove', '1,0,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object10, 'activate', 'menuFilters')
QtTesting.playCommand(object11, 'activate', 'MaterialInterfaceFilter')
object23 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/SelectMassArray/1QHeaderView0'
QtTesting.playCommand(object23, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object23, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/Viewport'
QtTestingImage.compareImage(snapshotWidget,
                            'CTHAMRMaterialInterfaceFilter.png', 300, 300)
#/usr/bin/env python

#Tests manta server side rendering for CS mode
#MantaTest.py tests client side rendering in builtin and CS mode

import QtTesting
import QtTestingImage

#TODO fix test recording so that it actually records these events
#most of which I had to hack in by hand

#force server side rendering by setting threshold to 0
object2 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object2, 'activate', 'actionEditSettings')
objectb2 = 'pqClientMainWindow/ApplicationSettings/PageNames'
QtTesting.playCommand(objectb2, 'setCurrent', '4.0')
QtTesting.playCommand(objectb2, 'expand', '4.0')
QtTesting.playCommand(objectb2, 'setCurrent', '4.0.2.0')
objectb3 = 'pqClientMainWindow/ApplicationSettings/Stack/pqGlobalRenderViewOptions/stackedWidget/Server/compositingParameters/compositeThreshold'
QtTesting.playCommand(objectb3, 'set_int', '0')
objectb4 = 'pqClientMainWindow/ApplicationSettings/CloseButton'
QtTesting.playCommand(objectb4, 'activate', '')

#load manta plugin on client and server sides
hack1='pqClientMainWindow/menubar'
QtTesting.playCommand(hack1, 'activate', 'menuTools')
hack2='pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(hack2, 'activate', 'actionManage_Plugins')
object1 = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(object1, 'setCurrent', 'MantaView')
object2 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
Пример #35
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object1, 'activate', '')
object2 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(
    object2, 'filesSelected',
    '$PARAVIEW_DATA_ROOT/Data/SPCTH/Dave_Karelitz_Small/spcth_a')
object3 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/CellArrayStatus/1QHeaderView0'
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
object4 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'pqClientMainWindow/representationToolbar/displayRepresentation/comboBox'
QtTesting.playCommand(object5, 'set_string', 'Surface')
object6 = 'pqClientMainWindow/cameraToolbar/actionNegativeY'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/variableToolbar/displayColor/Variables'
QtTesting.playCommand(object7, 'set_string', 'Pressure (dynes/cm^2^)')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'CTHAMRBaseline.png', 300, 300)
# /usr/bin/env python

import QtTesting

object1 = "pqClientMainWindow/menubar/menuSources"
QtTesting.playCommand(object1, "activate", "RTAnalyticSource")
object2 = "pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/Accept"
QtTesting.playCommand(object2, "activate", "")
object3 = "pqClientMainWindow/menubar/menuFilters/Common"
QtTesting.playCommand(object3, "activate", "Contour")
QtTesting.playCommand(object2, "activate", "")
object5 = "pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/1pqCollapsedGroup1/pqSampleScalarWidget"
QtTesting.setProperty(object5, "samples", "120")
QtTesting.playCommand(object2, "activate", "")
QtTesting.setProperty(object5, "samples", "120;130;140;150")
QtTesting.playCommand(object2, "activate", "")
object1 = "pqClientMainWindow/menubar/menuEdit"
QtTesting.playCommand(object1, "activate", "actionEditUndo")
# Need to wait a moment to allow the GUI to update.
import time

time.sleep(1)
val = QtTesting.getProperty(object5, "samples")

if val != "120":
    import exceptions

    raise exceptions.RuntimeError, "Expecting 120, received: " + val
Пример #37
0
#/usr/bin/env python

import QtTesting
import QtTestingImage
import time

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'Wavelet')
object2 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object6 = 'pqClientMainWindow/1QTabBar1'
QtTesting.playCommand(object6, 'set_tab_with_text', 'Display')
object24 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/pqDisplayProxyEditor/StyleGroup/StyleRepresentation/comboBox'
QtTesting.playCommand(object24, 'set_string', 'Surface')
object25 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/pqDisplayProxyEditor/ColorGroup/ColorBy/Variables'
QtTesting.playCommand(object25, 'set_string', 'RTData')
QtTesting.playCommand(object6, 'set_tab_with_text', 'Properties')
object3 = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/SplitHorizontal'
QtTesting.playCommand(object3, 'activate', '')

QtTesting.playCommand(object1, 'activate', 'Arrow')
QtTesting.playCommand(object2, 'activate', '')
object4 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Delete'
QtTesting.playCommand(object4, 'activate', '')

object4 = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Splitter.0/Frame.2/SplitVertical'
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'Sphere')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.playCommand(object6, 'set_tab_with_text', 'Display')
object8 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/Form/ViewGroup/ViewData'
Пример #38
0
#/usr/bin/env python

import QtTesting

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'RTAnalyticSource')
object2 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/menubar/menuFilters/Common'
QtTesting.playCommand(object3, 'activate', 'Contour')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/1pqCollapsedGroup1/pqSampleScalarWidget'
QtTesting.setProperty(object5, 'samples', '120')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.setProperty(object5, 'samples', '120;130;140;150')
QtTesting.playCommand(object2, 'activate', '')
object1 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object1, 'activate', 'actionEditUndo')
# Need to wait a moment to allow the GUI to update.
import time
time.sleep(1)
val = QtTesting.getProperty(object5, 'samples')

if val != "120":
    import exceptions
    raise exceptions.RuntimeError, "Expecting 120, received: " + val
else:
    print "Value comparison successful -- Test passed."
def test_compare_image(name):
    #save image the old fashioned way to make sure we loop
    print "comparing " + name
    QtTesting.playCommand(object1008, 'pause', '2000')
    object1009 = 'pqClientMainWindow/menubar/menu_File'
    QtTesting.playCommand(object1009, 'activate', 'actionFileSaveScreenshot')
    object1010 = 'pqClientMainWindow/SaveSnapshotDialog/width'
    QtTesting.playCommand(object1010, 'set_string', '300')
    object1011 = 'pqClientMainWindow/SaveSnapshotDialog/height'
    QtTesting.playCommand(object1011, 'set_string', '300')
    object1013 = 'pqClientMainWindow/SaveSnapshotDialog/ok'
    QtTesting.playCommand(object1013, 'activate', '')
    object1014 = 'pqClientMainWindow/FileSaveScreenshotDialog'
    QtTesting.playCommand(object1014, 'remove', '$PARAVIEW_TEST_ROOT/' + name)
    QtTesting.playCommand(object1014, 'filesSelected',
                          '$PARAVIEW_TEST_ROOT/' + name)
    QtTesting.playCommand(object1008, 'pause', '2000')
    QtTestingImage.compareImage('$PARAVIEW_TEST_ROOT/' + name, name)
Пример #40
0
#/usr/bin/env python

#Tests manta client side rendering for both builtin and CS mode
#MantaServerSideTest.py tests server side rendering in CS mode

import QtTesting
import QtTestingImage

#load manta plugin on client and server sides
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuTools')
hack2 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(hack2, 'activate', 'actionManage_Plugins')
objectA = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(objectA, 'setCurrent', 'MantaView')
object2 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
QtTesting.playCommand(object2, 'activate', '')
objecta1 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/remotePlugins'
QtTesting.playCommand(objecta1, 'setCurrent', 'MantaView')
objecta2 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/loadSelected_Remote'
QtTesting.playCommand(objecta2, 'activate', '')
object3 = 'pqClientMainWindow/PluginManagerDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object3, 'activate', '')

#create two manta and one gl window
object6 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseAction'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/1QWidget0/1QScrollArea0/qt_scrollarea_viewport/EmptyView/ConvertActionsFrame/Manta'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalAction'
QtTesting.playCommand(object8, 'activate', '')
Пример #41
0
#/usr/bin/env python

import QtTesting
import QtTestingImage

object1 = 'MainWindow/menubar/menuFile'
QtTesting.playCommand(object1, 'activate', 'actionFileLoadServerState')
##object2 = 'MainWindow/ServerStartupBrowser/connect'
#QtTesting.playCommand(object2, 'activate', '')
object3 = 'MainWindow/FileLoadServerStateDialog'
QtTesting.playCommand(object3, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/LoadStateMultiView.pvsm')
object4 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/MaximizeButton'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'MainWindow/MultiViewManager/MaximizeFrame/0/MultiViewFrameMenu/RestoreButton'
QtTesting.playCommand(object5, 'activate', '')
object6 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object8, 'activate', '')
object9 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/SplitHorizontalButton'
QtTesting.playCommand(object9, 'activate', '')
object10 = 'MainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView'
QtTesting.playCommand(object10, 'currentChanged', '/0/2|0')
#QtTesting.playCommand(object10, 'currentChanged', '/0/2|1')
object11 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QTabBar0'
QtTesting.playCommand(object11, 'set_tab', '1')
QtTesting.playCommand(object1, 'activate', 'actionFileSaveServerState')
object13 = 'MainWindow/FileSaveServerStateDialog'
QtTesting.playCommand(object13, 'filesSelected', '$PARAVIEW_TEST_ROOT/TestMultiView.pvsm')
#/usr/bin/env python

import QtTesting
import QtTestingImage

# Always render on server.  Nonlinear wireframes do not work when delivering to client (bug #10676).
object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menu_Edit')
object2 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object2, 'activate', 'actionEditSettings')
object3 = 'pqClientMainWindow/ApplicationSettings/PageNames'
QtTesting.playCommand(object3, 'expand', '4.0')
QtTesting.playCommand(object3, 'setCurrent', '4.0.2.0')
object4 = 'pqClientMainWindow/ApplicationSettings/Stack/pqGlobalRenderViewOptions/stackedWidget/Server/compositingParameters/compositeThreshold'
QtTesting.playCommand(object4, 'set_int', '0')
object5 = 'pqClientMainWindow/ApplicationSettings/CloseButton'
QtTesting.playCommand(object5, 'activate', '')

# Load the file.
object6 = 'pqClientMainWindow/MainControlsToolbar/actionOpenData'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/FileOpenDialog'
QtTesting.playCommand(object7, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/quadraticTetra01.vtu')
object8 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Accept'
QtTesting.playCommand(object8, 'activate', '')

# Edit the color map to capture negative values that occur in the nonlinear interpolation.
#object9 = 'pqClientMainWindow/variableToolbar/actionEditColorMap'
#QtTesting.playCommand(object9, 'activate', '')
#object10 = 'pqClientMainWindow/pqColorScaleDialog/ColorTabs/qt_tabwidget_stackedwidget/ScalePage/UseAutoRescale'
#QtTesting.playCommand(object10, 'set_boolean', 'false')
Пример #43
0
#/usr/bin/env python

import QtTesting
import QtTestingImage


#############################################################################
# Load the SLACTools plugin.

object1 = 'pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuTools')
object2 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object2, 'activate', 'actionManage_Plugins')

object3 = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(object3, 'setCurrent', 'SLACTools')
object4 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
QtTesting.playCommand(object4, 'activate', '')

object5 = 'pqClientMainWindow/PluginManagerDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object5, 'activate', '')


#############################################################################
# Load the pic-example SLAC files.

object6 = 'pqSLACActionHolder/actionDataLoadManager'
QtTesting.playCommand(object6, 'activate', '')

object7 = 'pqClientMainWindow/pqSLACDataLoadManager/meshFile/FileButton'
QtTesting.playCommand(object7, 'activate', '')
Пример #44
0
#/usr/bin/env python

#Tests manta client side rendering for both builtin and CS mode
#MantaServerSideTest.py tests server side rendering in CS mode

import QtTesting
import QtTestingImage

#load manta plugin on client and server sides
object1='pqClientMainWindow/menubar'
QtTesting.playCommand(object1, 'activate', 'menuTools')
hack2='pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(hack2, 'activate', 'actionManage_Plugins')
objectA = 'pqClientMainWindow/PluginManagerDialog/localGroup/localPlugins'
QtTesting.playCommand(objectA, 'setCurrent', 'MantaView')
object2 = 'pqClientMainWindow/PluginManagerDialog/localGroup/loadSelected_Local'
QtTesting.playCommand(object2, 'activate', '')
objecta1 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/remotePlugins'
QtTesting.playCommand(objecta1, 'setCurrent', 'MantaView')
objecta2 = 'pqClientMainWindow/PluginManagerDialog/remoteGroup/loadSelected_Remote'
QtTesting.playCommand(objecta2, 'activate', '')
object3 = 'pqClientMainWindow/PluginManagerDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object3, 'activate', '')

#create two manta and one gl window
object6 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseAction'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/1QWidget0/1QScrollArea0/qt_scrollarea_viewport/EmptyView/ConvertActionsFrame/Manta'
QtTesting.playCommand(object7, 'activate', '')
object8 = 'pqClientMainWindow/centralwidget/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalAction'
QtTesting.playCommand(object8, 'activate', '')
Пример #45
0
#/usr/bin/env python

import QtTesting
import sys

lib1name = 'libAdaptiveSSPlugin.so'
lib2name = 'libAdaptiveCSPlugin.so'
if sys.platform == 'win32':
    lib1name = 'AdaptiveSSPlugin.dll'
    lib2name = 'AdaptiveCSPlugin.dll'
if sys.platform == 'darwin':
    lib1name = 'libAdaptiveSSPlugin.dylib'
    lib2name = 'libAdaptiveCSPlugin.dylib'

object1 = 'pqClientMainWindow/menubar/menuTools'
QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
object2 = "pqClientMainWindow/pqPluginDialog/localGroup/loadLocal"
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
QtTesting.playCommand(object3, 'filesSelected', lib1name)
object4 = 'pqClientMainWindow/pqPluginDialog/buttonBox/1QPushButton0'
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'actionManage_Plugins')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/pqPluginDialog/pqFileDialog'
QtTesting.playCommand(object3, 'filesSelected', lib2name)
QtTesting.playCommand(object4, 'activate', '')
object6 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton'
QtTesting.playCommand(object6, 'activate', '')
object7 = 'pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/1QWidget0/1QScrollArea0/qt_scrollarea_viewport/EmptyView/ConvertActionsFrame/1QPushButton0'
QtTesting.playCommand(object7, 'activate', '')
Пример #46
0
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
  QtTesting.playCommand(fdName, 'set_string', 'Filec')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filec.png')
  QtTesting.playCommand(fdOk, 'activate', '')
  checkFile('Filec.png')
  QtTesting.playCommand(mode, 'set_string', 'Existing File')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filea')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(filter, 'set_string', 'Images (*.png;*.bmp)')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/7|0')
  QtTesting.playCommand(fdOk, 'activate', '')
  checkFile('Filec.bmp')



QtTesting.playCommand(connection, 'set_string', 'Local')
runTests()
QtTesting.playCommand(connection, 'set_string', 'Remote')
runTests()


Пример #47
0
#/usr/bin/env python

import QtTesting
import QtTestingImage
import time

object1 = 'MainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'Wavelet')
object2 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object6 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_tabbar'
QtTesting.playCommand(object6, 'set_tab', '1')
object24 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/1QScrollArea0/qt_scrollarea_viewport/1pqDisplayProxyEditorWidget0/pqDisplayProxyEditor/StyleGroup/StyleRepresentation/comboBox'
QtTesting.playCommand(object24, 'set_string', 'Surface')
object25 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/1QScrollArea0/qt_scrollarea_viewport/1pqDisplayProxyEditorWidget0/pqDisplayProxyEditor/ColorGroup/ColorBy/Variables'
QtTesting.playCommand(object25, 'set_string', 'RTData')
QtTesting.playCommand(object6, 'set_tab', '0')
object3 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/SplitHorizontalButton'
QtTesting.playCommand(object3, 'activate', '')

QtTesting.playCommand(object1, 'activate', 'Arrow')
QtTesting.playCommand(object2, 'activate', '')
object4 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/qt_tabwidget_stackedwidget/objectInspector/Delete'
QtTesting.playCommand(object4, 'activate', '')

object4 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/SplitVerticalButton'
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'Sphere')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:1/1/Viewport'
QtTesting.playCommand(object5, 'mousePress', '(0.533784,0.680147,1,1,0)')
Пример #48
0
def runTests():
  #  initialize
  QtTesting.playCommand(filter, 'set_string', '')
  QtTesting.playCommand(mode, 'set_string', 'Any File')
  #
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdCancel, 'activate', '')
  QtTesting.playCommand(filter, 'set_string', 'File[12].?n?')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdMsgOk, 'activate', '')
  checkFile('Filea.png')
  QtTesting.playCommand(filter, 'set_string', '*.png')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/1|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/2|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/3|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/4|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdMsgOk, 'activate', '')
  checkFile('Filec.png')
  QtTesting.playCommand(mode, 'set_string', 'Existing File')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/4|0')
  QtTesting.playCommand(fdOk, 'activate', '')
  checkFile('Fileb.png')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/2|0')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdUp, 'activate', '')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdUp, 'activate', '')
  QtTesting.playCommand(fdCancel, 'activate', '')
  QtTesting.playCommand(mode, 'set_string', 'Existing Files')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/5|0')
  QtTesting.playCommand(fdName, 'set_string', 'Filec')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filec.png')
  QtTesting.playCommand(fdOk, 'activate', '')
  checkFile('Filec.png')
  QtTesting.playCommand(mode, 'set_string', 'Existing File')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filea')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(fdName, 'set_string', 'Filea.png')
  QtTesting.playCommand(fdOk, 'activate', '')
  QtTesting.playCommand(filter, 'set_string', 'Images (*.png;*.bmp)')
  QtTesting.playCommand(openDialog, 'activate', '')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/0|0')
  QtTesting.playCommand(fdFiles, 'currentChanged', '/7|0')
  QtTesting.playCommand(fdOk, 'activate', '')
  checkFile('Filec.bmp')
Пример #49
0
def test_compare_image(name):
  #save image the old fashioned way to make sure we loop
  print "comparing "+name
  QtTesting.playCommand(object1008, 'pause', '2000')
  object1009 = 'pqClientMainWindow/menubar/menu_File'
  QtTesting.playCommand(object1009, 'activate', 'actionFileSaveScreenshot')
  object1010 = 'pqClientMainWindow/SaveSnapshotDialog/width'
  QtTesting.playCommand(object1010, 'set_string', '300')
  object1011 = 'pqClientMainWindow/SaveSnapshotDialog/height'
  QtTesting.playCommand(object1011, 'set_string', '300')
  object1013 = 'pqClientMainWindow/SaveSnapshotDialog/ok'
  QtTesting.playCommand(object1013, 'activate', '')
  object1014 = 'pqClientMainWindow/FileSaveScreenshotDialog'
  QtTesting.playCommand(object1014, 'remove',
                        '$PARAVIEW_TEST_ROOT/'+name)
  QtTesting.playCommand(object1014, 'filesSelected', '$PARAVIEW_TEST_ROOT/'+name)
  QtTesting.playCommand(object1008, 'pause', '2000')
  QtTestingImage.compareImage('$PARAVIEW_TEST_ROOT/'+name, name);
Пример #50
0
#/usr/bin/env python

import QtTesting

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'RTAnalyticSource')
object2 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object3 = 'pqClientMainWindow/menubar/menuFilters/Common'
QtTesting.playCommand(object3, 'activate', 'Contour')
QtTesting.playCommand(object2, 'activate', '')
object5 = 'pqClientMainWindow/objectInspectorDock/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/1pqCollapsedGroup1/pqSampleScalarWidget'
QtTesting.setProperty(object5, 'samples', '120')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.setProperty(object5, 'samples', '120;130;140;150')
QtTesting.playCommand(object2, 'activate', '')
object1 = 'pqClientMainWindow/menubar/menu_Edit'
QtTesting.playCommand(object1, 'activate', 'actionEditUndo')
# Need to wait a moment to allow the GUI to update.
import time
time.sleep(1)
val = QtTesting.getProperty(object5, 'samples')

if val != "120":
    import exceptions
    raise exceptions.RuntimeError, "Expecting 120, received: " + val
else:
    print "Value comparison successful -- Test passed."
Пример #51
0
#/usr/bin/env python

import QtTesting
import QtTestingImage
import time

object1 = 'MainWindow/mainToolBar/1QToolButton0'
QtTesting.playCommand(object1, 'activate', '')
object3 = 'MainWindow/FileOpenDialog'
QtTesting.playCommand(object3, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/dualSphereAnimation.pvd')
object4 = 'MainWindow/objectInspectorDock/1pqProxyTabWidget0/1QStackedWidget0/objectInspector/Accept'
QtTesting.playCommand(object4, 'activate', '')
object5 = 'MainWindow/VCRToolbar/1QToolButton2'
QtTesting.playCommand(object5, 'activate', '')

while QtTesting.getProperty(object5, 'text') != 'Play':
  time.sleep(0.2)

snapshotWidget = 'MainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'VCRAnimation.png', 300, 300);

#/usr/bin/env python

import QtTesting
import QtTestingImage
import time

object1 = 'pqClientMainWindow/menubar/menuSources'
QtTesting.playCommand(object1, 'activate', 'Wavelet')
object2 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Accept'
QtTesting.playCommand(object2, 'activate', '')
object6 = 'pqClientMainWindow/1QTabBar1'
QtTesting.playCommand(object6, 'set_tab_with_text', 'Display')
object24 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/pqDisplayProxyEditor/StyleGroup/StyleRepresentation/comboBox'
QtTesting.playCommand(object24, 'set_string', 'Surface')
object25 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/pqDisplayProxyEditor/ColorGroup/ColorBy/Variables'
QtTesting.playCommand(object25, 'set_string', 'RTData')
QtTesting.playCommand(object6, 'set_tab_with_text', 'Properties')
object3 = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/SplitHorizontal'
QtTesting.playCommand(object3, 'activate', '')

QtTesting.playCommand(object1, 'activate', 'Arrow')
QtTesting.playCommand(object2, 'activate', '')
object4 = 'pqClientMainWindow/objectInspectorDock/objectInspector/Delete'
QtTesting.playCommand(object4, 'activate', '')

object4 = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Splitter.0/Frame.2/SplitVertical'
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object1, 'activate', 'Sphere')
QtTesting.playCommand(object2, 'activate', '')
QtTesting.playCommand(object6, 'set_tab_with_text', 'Display')
object8 = 'pqClientMainWindow/displayDock/displayWidgetFrame/displayScrollArea/qt_scrollarea_viewport/displayWidget/Form/ViewGroup/ViewData'
#/usr/bin/env python

import QtTesting
import QtTestingImage

QtTesting.playCommand(object1, 'activate', '')
QtTesting.playCommand(object2, 'filesSelected', '$PARAVIEW_DATA_ROOT/Data/SPCTH/Dave_Karelitz_Small/spcth_a')
QtTesting.playCommand(object3, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object3, 'mouseMove', '1,0,0,0,0,0')
QtTesting.playCommand(object3, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
QtTesting.playCommand(object10, 'activate', 'menuFilters')
QtTesting.playCommand(object11, 'activate', 'MaterialInterfaceFilter')
object23 = 'pqClientMainWindow/proxyTabDock/proxyTabWidget/qt_tabwidget_stackedwidget/objectInspector/ScrollArea/qt_scrollarea_viewport/PanelArea/Editor/SelectMassArray/1QHeaderView0'
QtTesting.playCommand(object23, 'mousePress', '1,1,0,0,0,0')
QtTesting.playCommand(object23, 'mouseRelease', '1,0,0,0,0,0')
QtTesting.playCommand(object4, 'activate', '')
# DO_IMAGE_COMPARE
snapshotWidget = 'pqClientMainWindow/centralwidget/MultiViewWidget/CoreWidget/qt_tabwidget_stackedwidget/MultiViewWidget1/Frame.0/Viewport'
QtTestingImage.compareImage(snapshotWidget, 'CTHAMRMaterialInterfaceFilter.png', 300, 300)
# /usr/bin/env python

import QtTesting
import QtTestingImage

object1 = "pqClientMainWindow/menubar/menuFile"
QtTesting.playCommand(object1, "activate", "actionFileLoadServerState")
##object2 = 'pqClientMainWindow/ServerStartupBrowser/connect'
# QtTesting.playCommand(object2, 'activate', '')
object3 = "pqClientMainWindow/FileLoadServerStateDialog"
QtTesting.playCommand(object3, "filesSelected", "$PARAVIEW_DATA_ROOT/Data/LoadStateMultiView.pvsm")
object4 = "pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/MaximizeButton"
QtTesting.playCommand(object4, "activate", "")
object5 = "pqClientMainWindow/MultiViewManager/MaximizeFrame/0/MultiViewFrameMenu/RestoreButton"
QtTesting.playCommand(object5, "activate", "")
object6 = "pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/MultiViewSplitter:0/0/MultiViewFrameMenu/CloseButton"
QtTesting.playCommand(object6, "activate", "")
object7 = "pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/0/MultiViewFrameMenu/CloseButton"
QtTesting.playCommand(object7, "activate", "")
object8 = "pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/CloseButton"
QtTesting.playCommand(object8, "activate", "")
object9 = (
    "pqClientMainWindow/MultiViewManager/SplitterFrame/MultiViewSplitter/1/MultiViewFrameMenu/SplitHorizontalButton"
)
QtTesting.playCommand(object9, "activate", "")
object10 = "pqClientMainWindow/pipelineBrowserDock/pipelineBrowser/PipelineView"
QtTesting.playCommand(object10, "currentChanged", "/0/2|0")
# QtTesting.playCommand(object10, 'currentChanged', '/0/2|1')
object11 = "pqClientMainWindow/objectInspectorDock/1pqProxyTabWidget0/1QTabBar0"
QtTesting.playCommand(object11, "set_tab", "1")
QtTesting.playCommand(object1, "activate", "actionFileSaveServerState")