summaryrefslogtreecommitdiff
path: root/uitest
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-02-14 00:45:12 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2017-02-18 04:48:40 +0000
commit7ec0500e20cf273d70c4fbddb4063b8f8295307c (patch)
treecfb542ae37005ce03f88b1c96977095044e213ce /uitest
parent19d52e56a4581bb12bc271765feec7b8ab78c45b (diff)
use special method to close dialog through button click
Change-Id: Id884cc75503cb433742f9316d9647cff801565f7 Reviewed-on: https://gerrit.libreoffice.org/34230 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'uitest')
-rw-r--r--uitest/calc_tests/about_test.py2
-rw-r--r--uitest/calc_tests/create_chart.py12
-rw-r--r--uitest/calc_tests/create_range_name.py4
-rw-r--r--uitest/calc_tests/edit_chart.py2
-rw-r--r--uitest/calc_tests/function_wizard.py2
-rw-r--r--uitest/calc_tests/tdf105411.py2
-rw-r--r--uitest/calc_tests/tdf105466.py2
-rw-r--r--uitest/calc_tests/tdf96453.py2
-rw-r--r--uitest/demo_ui/radiobutton.py2
-rw-r--r--uitest/demo_ui/tabdialog.py4
-rw-r--r--uitest/uitest/test.py2
11 files changed, 18 insertions, 18 deletions
diff --git a/uitest/calc_tests/about_test.py b/uitest/calc_tests/about_test.py
index 016c486d1f25..a5082ee6c8e2 100644
--- a/uitest/calc_tests/about_test.py
+++ b/uitest/calc_tests/about_test.py
@@ -18,7 +18,7 @@ class AboutDlgTest(UITestCase):
xAboutDlg = self.xUITest.getTopFocusWindow()
xCloseBtn = xAboutDlg.getChild("close")
- xCloseBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xCloseBtn)
self.ui_test.close_doc()
diff --git a/uitest/calc_tests/create_chart.py b/uitest/calc_tests/create_chart.py
index d98eeffc4e67..427b4ce2dd1d 100644
--- a/uitest/calc_tests/create_chart.py
+++ b/uitest/calc_tests/create_chart.py
@@ -39,7 +39,7 @@ class CalcChartUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xCancelBtn = xChartDlg.getChild("cancel")
- xCancelBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.close_doc()
@@ -54,7 +54,7 @@ class CalcChartUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xOkBtn = xChartDlg.getChild("finish")
- xOkBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xOkBtn)
self.ui_test.close_doc()
@@ -78,7 +78,7 @@ class CalcChartUIDemo(UITestCase):
xDataInCols.executeAction("CLICK", tuple())
xCancelBtn = xChartDlg.getChild("finish")
- xCancelBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.close_doc()
@@ -95,7 +95,7 @@ class CalcChartUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xNextBtn = xChartDlg.getChild("finish")
- xNextBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xNextBtn)
xGridWindow.executeAction("DESELECT", mkPropertyValues({"OBJECT": ""}))
@@ -118,7 +118,7 @@ class CalcChartUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xNextBtn = xChartDlg.getChild("finish")
- xNextBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xNextBtn)
xGridWindow.executeAction("DESELECT", mkPropertyValues({"OBJECT": ""}))
@@ -144,7 +144,7 @@ class CalcChartUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xNextBtn = xChartDlg.getChild("finish")
- xNextBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xNextBtn)
xGridWindow.executeAction("DESELECT", mkPropertyValues({"OBJECT": ""}))
diff --git a/uitest/calc_tests/create_range_name.py b/uitest/calc_tests/create_range_name.py
index 1ab7805bf970..1babca7c0a58 100644
--- a/uitest/calc_tests/create_range_name.py
+++ b/uitest/calc_tests/create_range_name.py
@@ -24,7 +24,7 @@ class CreateRangeNameTest(UITestCase):
type_text(xEdit, "simpleRangeName")
xAddBtn = xAddNameDlg.getChild("add")
- xAddBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xAddBtn)
self.ui_test.close_doc()
@@ -43,7 +43,7 @@ class CreateRangeNameTest(UITestCase):
select_pos(xScope, "1")
xAddBtn = xAddNameDlg.getChild("add")
- xAddBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xAddBtn)
self.ui_test.close_doc()
diff --git a/uitest/calc_tests/edit_chart.py b/uitest/calc_tests/edit_chart.py
index a8aa36e70c03..4d44d5283c64 100644
--- a/uitest/calc_tests/edit_chart.py
+++ b/uitest/calc_tests/edit_chart.py
@@ -42,7 +42,7 @@ class CalcChartEditUIDemo(UITestCase):
xChartDlg = self.xUITest.getTopFocusWindow()
xNextBtn = xChartDlg.getChild("finish")
- xNextBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xNextBtn)
xGridWindow.executeAction("DESELECT", mkPropertyValues({"OBJECT": ""}))
diff --git a/uitest/calc_tests/function_wizard.py b/uitest/calc_tests/function_wizard.py
index 73870711a5dc..13b83350927f 100644
--- a/uitest/calc_tests/function_wizard.py
+++ b/uitest/calc_tests/function_wizard.py
@@ -22,7 +22,7 @@ class FunctionWizardTest(UITestCase):
xArrayChkBox.executeAction("CLICK", tuple())
xCancelBtn = xFunctionDlg.getChild("cancel")
- xCancelBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.close_doc()
diff --git a/uitest/calc_tests/tdf105411.py b/uitest/calc_tests/tdf105411.py
index c9910bc38a5b..8f08c2f22fb5 100644
--- a/uitest/calc_tests/tdf105411.py
+++ b/uitest/calc_tests/tdf105411.py
@@ -28,7 +28,7 @@ class tdf105411(UITestCase):
xCondFormatDlg = self.xUITest.getTopFocusWindow()
xOkBtn = xCondFormatDlg.getChild("ok")
- xOkBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xOkBtn)
self.ui_test.close_doc()
diff --git a/uitest/calc_tests/tdf105466.py b/uitest/calc_tests/tdf105466.py
index 6e3593be4d5d..e1cfd2d0a27e 100644
--- a/uitest/calc_tests/tdf105466.py
+++ b/uitest/calc_tests/tdf105466.py
@@ -23,7 +23,7 @@ class tdf105466(UITestCase):
xCondFormatDlg = self.xUITest.getTopFocusWindow()
xOkBtn = xCondFormatDlg.getChild("ok")
- xOkBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xOkBtn)
self.ui_test.close_doc()
diff --git a/uitest/calc_tests/tdf96453.py b/uitest/calc_tests/tdf96453.py
index 94f047d7eb03..696fff87da3f 100644
--- a/uitest/calc_tests/tdf96453.py
+++ b/uitest/calc_tests/tdf96453.py
@@ -82,7 +82,7 @@ class ConditionalFormatDlgTest(UITestCase):
# close the conditional format manager
xCancelBtn = xCondFormatMgr.getChild("cancel")
- xCancelBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xCancelBtn)
self.ui_test.close_doc()
diff --git a/uitest/demo_ui/radiobutton.py b/uitest/demo_ui/radiobutton.py
index 34c6dee6972f..bb2f5bd07440 100644
--- a/uitest/demo_ui/radiobutton.py
+++ b/uitest/demo_ui/radiobutton.py
@@ -33,7 +33,7 @@ class RadioButtonTest(UITestCase):
xNegativeNumRedCB.executeAction("CLICK",tuple())
okBtn = xCellsDlg.getChild("ok")
- okBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(okBtn)
self.ui_test.close_doc()
diff --git a/uitest/demo_ui/tabdialog.py b/uitest/demo_ui/tabdialog.py
index f9251178d259..ed46379ab05b 100644
--- a/uitest/demo_ui/tabdialog.py
+++ b/uitest/demo_ui/tabdialog.py
@@ -22,7 +22,7 @@ class TabDialogTest(UITestCase):
select_pos(xCellsDlg, "1")
xOkBtn = xCellsDlg.getChild("ok")
- xOkBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xOkBtn)
self.ui_test.close_doc()
@@ -38,7 +38,7 @@ class TabDialogTest(UITestCase):
xCellsDlg.executeAction("SELECT", propsUNO)
xOkBtn = xCellsDlg.getChild("ok")
- xOkBtn.executeAction("CLICK", tuple())
+ self.ui_test.close_dialog_through_button(xOkBtn)
self.ui_test.close_doc()
diff --git a/uitest/uitest/test.py b/uitest/uitest/test.py
index 0f8cee182754..312232930c49 100644
--- a/uitest/uitest/test.py
+++ b/uitest/uitest/test.py
@@ -144,7 +144,7 @@ class UITest(object):
if event.hasExecuted("DialogExecute"):
xCloseDlg = self._xUITest.getTopFocusWindow()
xNoBtn = xCloseDlg.getChild("discard")
- xNoBtn.executeAction("CLICK", tuple())
+ self.close_dialog_through_button(xNoBtn);
return
elif event.hasExecuted("OnViewClosed"):
return