summaryrefslogtreecommitdiff
path: root/sw/qa/uitest/writer_tests7
diff options
context:
space:
mode:
authorXisco Fauli <xiscofauli@libreoffice.org>2021-06-29 11:44:54 +0200
committerXisco Fauli <xiscofauli@libreoffice.org>2021-06-29 15:10:03 +0200
commit5b8a13486d3809066e663549879c209992d5479d (patch)
tree8c2701d8827e24eb7f36eb707c20905c41653485 /sw/qa/uitest/writer_tests7
parentd0172f785a5973dbe5ea585eabfa7a4671b38775 (diff)
uitest: combine execute_dialog_through_command methods
Change-Id: Iaa03d37a9ac3862b8cb08a81e37a611632433880 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/118077 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Diffstat (limited to 'sw/qa/uitest/writer_tests7')
-rw-r--r--sw/qa/uitest/writer_tests7/apply_line_cap.py6
-rw-r--r--sw/qa/uitest/writer_tests7/tdf104795.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf109083.py4
-rw-r--r--sw/qa/uitest/writer_tests7/tdf115853.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf119661.py6
-rw-r--r--sw/qa/uitest/writer_tests7/tdf122780.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf131936.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf132169.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf133348.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf134243.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf137802.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf137803.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf139301.py4
-rw-r--r--sw/qa/uitest/writer_tests7/tdf140117.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf140863.py6
-rw-r--r--sw/qa/uitest/writer_tests7/tdf141557.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf46561.py2
-rw-r--r--sw/qa/uitest/writer_tests7/tdf90401.py4
18 files changed, 27 insertions, 27 deletions
diff --git a/sw/qa/uitest/writer_tests7/apply_line_cap.py b/sw/qa/uitest/writer_tests7/apply_line_cap.py
index 9e308acc0ff8..7df47a6b52b5 100644
--- a/sw/qa/uitest/writer_tests7/apply_line_cap.py
+++ b/sw/qa/uitest/writer_tests7/apply_line_cap.py
@@ -22,7 +22,7 @@ class apply_line_cap(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# line setting dialog window
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
# get cap style combo box
xCapStyle = xFormatLineDlg.getChild("LB_CAP_STYLE")
@@ -46,7 +46,7 @@ class apply_line_cap(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# line setting dialog window
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
# get cap style combo box
xCapStyle = xFormatLineDlg.getChild("LB_CAP_STYLE")
@@ -71,7 +71,7 @@ class apply_line_cap(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# line setting dialog window
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
# get cap style combo box
xCapStyle = xFormatLineDlg.getChild("LB_CAP_STYLE")
diff --git a/sw/qa/uitest/writer_tests7/tdf104795.py b/sw/qa/uitest/writer_tests7/tdf104795.py
index 00b71bb2b97c..98be1cf366b2 100644
--- a/sw/qa/uitest/writer_tests7/tdf104795.py
+++ b/sw/qa/uitest/writer_tests7/tdf104795.py
@@ -14,7 +14,7 @@ class tdf104795(UITestCase):
def test_tdf104795(self):
with self.ui_test.load_file(get_url_for_data_file("tdf104795.odt")) as writer_doc:
- with self.ui_test.execute_dialog_through_command_guarded(".uno:SetDocumentProperties") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:SetDocumentProperties") as xDialog:
sShowSignedText = get_state_as_dict(xDialog.getChild('showsigned'))['Text']
diff --git a/sw/qa/uitest/writer_tests7/tdf109083.py b/sw/qa/uitest/writer_tests7/tdf109083.py
index eb83582b4431..500bc7150ddc 100644
--- a/sw/qa/uitest/writer_tests7/tdf109083.py
+++ b/sw/qa/uitest/writer_tests7/tdf109083.py
@@ -18,7 +18,7 @@ class tdf109083(UITestCase):
#generate two 2x2 tables with the same autoformat table style (Default Table Style)
#Note that this style is different than applying nothing!
for i in range(0, 2):
- with self.ui_test.execute_dialog_through_command_guarded(".uno:InsertTable") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:InsertTable") as xDialog:
formatlbinstable = xDialog.getChild("formatlbinstable")
entry = formatlbinstable.getChild("1")
entry.executeAction("SELECT", tuple())
@@ -45,7 +45,7 @@ class tdf109083(UITestCase):
#first row's cells must be yellow, second/last row's cells must be updated to yellow by now
for i in range (0,4):
- with self.ui_test.execute_dialog_through_command_guarded(".uno:TableDialog") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:TableDialog") as xDialog:
xTabs = xDialog.getChild("tabcontrol")
select_pos(xTabs, "4") #tab Background
btncolor = xDialog.getChild("btncolor")
diff --git a/sw/qa/uitest/writer_tests7/tdf115853.py b/sw/qa/uitest/writer_tests7/tdf115853.py
index 05825bf15043..fb0a0966a27c 100644
--- a/sw/qa/uitest/writer_tests7/tdf115853.py
+++ b/sw/qa/uitest/writer_tests7/tdf115853.py
@@ -16,7 +16,7 @@ class tdf115853(UITestCase):
def test_tdf115853(self):
self.ui_test.create_doc_in_start_center("writer")
- with self.ui_test.execute_dialog_through_command_guarded(".uno:SetDocumentProperties") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:SetDocumentProperties") as xDialog:
xTabs = xDialog.getChild("tabcontrol")
diff --git a/sw/qa/uitest/writer_tests7/tdf119661.py b/sw/qa/uitest/writer_tests7/tdf119661.py
index afdbba2dd99c..e1464b962c99 100644
--- a/sw/qa/uitest/writer_tests7/tdf119661.py
+++ b/sw/qa/uitest/writer_tests7/tdf119661.py
@@ -17,7 +17,7 @@ class tdf119661(UITestCase):
self.ui_test.create_doc_in_start_center("writer")
- with self.ui_test.execute_dialog_through_command_guarded(".uno:InsertGraphic", close_button="") as xOpenDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:InsertGraphic", close_button="") as xOpenDialog:
xFileName = xOpenDialog.getChild("file_name")
xFileName.executeAction("TYPE", mkPropertyValues({"TEXT": get_url_for_data_file("LibreOffice.jpg")}))
@@ -34,7 +34,7 @@ class tdf119661(UITestCase):
xOK = xWarnDialog.getChild("ok")
self.ui_test.close_dialog_through_button(xOK)
- with self.ui_test.execute_dialog_through_command_guarded(".uno:LinkDialog", close_button="close") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:LinkDialog", close_button="close") as xDialog:
sLinks = "TB_LINKS"
@@ -57,7 +57,7 @@ class tdf119661(UITestCase):
xFilePath = os.path.join(tempdir, "tdf119661-tmp.odt")
# Save Copy as
- with self.ui_test.execute_dialog_through_command_guarded(".uno:SaveAs", close_button="open") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:SaveAs", close_button="open") as xDialog:
xFileName = xDialog.getChild("file_name")
xFileName.executeAction("TYPE", mkPropertyValues({"KEYCODE":"CTRL+A"}))
diff --git a/sw/qa/uitest/writer_tests7/tdf122780.py b/sw/qa/uitest/writer_tests7/tdf122780.py
index a128f95eaf1c..957ef31dfd13 100644
--- a/sw/qa/uitest/writer_tests7/tdf122780.py
+++ b/sw/qa/uitest/writer_tests7/tdf122780.py
@@ -14,7 +14,7 @@ class tdf122780(UITestCase):
def test_tdf122780(self):
with self.ui_test.load_file(get_url_for_data_file("tdf122780.docx")) as writer_doc:
- with self.ui_test.execute_dialog_through_command_guarded(".uno:SetDocumentProperties") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:SetDocumentProperties") as xDialog:
# Without the fix in place, this test would have hung here
self.assertEqual("Normal_x005F", get_state_as_dict(xDialog.getChild('showtemplate'))['Text'][:12])
diff --git a/sw/qa/uitest/writer_tests7/tdf131936.py b/sw/qa/uitest/writer_tests7/tdf131936.py
index 07298084b2a7..773386b658ff 100644
--- a/sw/qa/uitest/writer_tests7/tdf131936.py
+++ b/sw/qa/uitest/writer_tests7/tdf131936.py
@@ -12,7 +12,7 @@ class tdf131936(UITestCase):
def test_tdf131936_saveas_docx_version(self):
with self.ui_test.load_file(get_url_for_data_file("tdf131936.docx")):
- with self.ui_test.execute_dialog_through_command_guarded(".uno:SaveAs", close_button="cancel") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:SaveAs", close_button="cancel") as xDialog:
time.sleep(DEFAULT_SLEEP)
xFileTypeCombo = xDialog.getChild("file_type")
state = get_state_as_dict(xFileTypeCombo)
diff --git a/sw/qa/uitest/writer_tests7/tdf132169.py b/sw/qa/uitest/writer_tests7/tdf132169.py
index 2466a7cb5545..393b6e1fa098 100644
--- a/sw/qa/uitest/writer_tests7/tdf132169.py
+++ b/sw/qa/uitest/writer_tests7/tdf132169.py
@@ -23,7 +23,7 @@ class tdf132169(UITestCase):
self.assertEqual(get_state_as_dict(xLineMetric)["Text"], "0.0 pt")
#Check changing value from dialog also works
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
xWidth = xFormatLineDlg.getChild('MTR_FLD_LINE_WIDTH')
type_text(xWidth, "4.0")
diff --git a/sw/qa/uitest/writer_tests7/tdf133348.py b/sw/qa/uitest/writer_tests7/tdf133348.py
index c5ebb726f4f9..a479b408a856 100644
--- a/sw/qa/uitest/writer_tests7/tdf133348.py
+++ b/sw/qa/uitest/writer_tests7/tdf133348.py
@@ -21,7 +21,7 @@ class tdf133348(UITestCase):
xArgs = mkPropertyValues({"Text": "C1"})
self.xUITest.executeCommandWithParameters(".uno:InsertAnnotation", xArgs)
- with self.ui_test.execute_dialog_through_command_guarded(".uno:OptionsTreeDialog") as xDialogOpt:
+ with self.ui_test.execute_dialog_through_command(".uno:OptionsTreeDialog") as xDialogOpt:
xPages = xDialogOpt.getChild("pages")
xEntry = xPages.getChild('0')
xEntry.executeAction("EXPAND", tuple())
diff --git a/sw/qa/uitest/writer_tests7/tdf134243.py b/sw/qa/uitest/writer_tests7/tdf134243.py
index 1e1c4a5db3f4..7ee7976ce18b 100644
--- a/sw/qa/uitest/writer_tests7/tdf134243.py
+++ b/sw/qa/uitest/writer_tests7/tdf134243.py
@@ -13,7 +13,7 @@ class tdf134243(UITestCase):
with self.ui_test.load_file(get_url_for_data_file("tdf134243.odt")) as writer_doc:
# Without the fix in place, it would hung launching the mailmerge wizard
- with self.ui_test.execute_dialog_through_command_guarded(".uno:MailMergeWizard", close_button="cancel"):
+ with self.ui_test.execute_dialog_through_command(".uno:MailMergeWizard", close_button="cancel"):
pass
# vim: set shiftwidth=4 softtabstop=4 expandtab:
diff --git a/sw/qa/uitest/writer_tests7/tdf137802.py b/sw/qa/uitest/writer_tests7/tdf137802.py
index c91642c2f9a3..424375b3df38 100644
--- a/sw/qa/uitest/writer_tests7/tdf137802.py
+++ b/sw/qa/uitest/writer_tests7/tdf137802.py
@@ -25,7 +25,7 @@ class tdf137802(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
- with self.ui_test.execute_dialog_through_command_guarded(".uno:TransformDialog") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:TransformDialog") as xDialog:
xDialog.getChild('topage').executeAction("CLICK", tuple())
diff --git a/sw/qa/uitest/writer_tests7/tdf137803.py b/sw/qa/uitest/writer_tests7/tdf137803.py
index 3fceb5cb814e..b1621adf55dd 100644
--- a/sw/qa/uitest/writer_tests7/tdf137803.py
+++ b/sw/qa/uitest/writer_tests7/tdf137803.py
@@ -18,7 +18,7 @@ class tdf137803(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# open textattrs dialog
- with self.ui_test.execute_dialog_through_command_guarded(".uno:TextAttributes") as TextDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:TextAttributes") as TextDialog:
# check autosize on
TSB_AUTOGROW_SIZE = TextDialog.getChild('TSB_AUTOGROW_SIZE')
diff --git a/sw/qa/uitest/writer_tests7/tdf139301.py b/sw/qa/uitest/writer_tests7/tdf139301.py
index d62e0db3c290..e34dce1fb31b 100644
--- a/sw/qa/uitest/writer_tests7/tdf139301.py
+++ b/sw/qa/uitest/writer_tests7/tdf139301.py
@@ -22,7 +22,7 @@ class tdf139301(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# line setting dialog window
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
# get line style combo box
xLineStyle = xFormatLineDlg.getChild("LB_LINE_STYLE")
@@ -45,7 +45,7 @@ class tdf139301(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
# line setting dialog window
- with self.ui_test.execute_dialog_through_command_guarded(".uno:FormatLine") as xFormatLineDlg:
+ with self.ui_test.execute_dialog_through_command(".uno:FormatLine") as xFormatLineDlg:
# get line style combo box
xLineStyle = xFormatLineDlg.getChild("LB_LINE_STYLE")
diff --git a/sw/qa/uitest/writer_tests7/tdf140117.py b/sw/qa/uitest/writer_tests7/tdf140117.py
index 07437903f755..bf3c69874e25 100644
--- a/sw/qa/uitest/writer_tests7/tdf140117.py
+++ b/sw/qa/uitest/writer_tests7/tdf140117.py
@@ -45,7 +45,7 @@ class tdf140117(UITestCase):
elif i == 2:
self.assertEqual("XXXXleft", xHeaderLeftText)
- with self.ui_test.execute_dialog_through_command_guarded(".uno:PageDialog") as PageDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:PageDialog") as PageDialog:
xTabs = PageDialog.getChild("tabcontrol")
select_pos(xTabs, "4")
diff --git a/sw/qa/uitest/writer_tests7/tdf140863.py b/sw/qa/uitest/writer_tests7/tdf140863.py
index bb558c15590b..a1a926af8223 100644
--- a/sw/qa/uitest/writer_tests7/tdf140863.py
+++ b/sw/qa/uitest/writer_tests7/tdf140863.py
@@ -15,7 +15,7 @@ class tdf140863(UITestCase):
self.ui_test.create_doc_in_start_center("writer")
# Insert one section
- with self.ui_test.execute_dialog_through_command_guarded(".uno:InsertSection"):
+ with self.ui_test.execute_dialog_through_command(".uno:InsertSection"):
pass
xWriterDoc = self.xUITest.getTopFocusWindow()
@@ -31,7 +31,7 @@ class tdf140863(UITestCase):
self.assertTrue(document.TextSections.Section1.IsVisible)
- with self.ui_test.execute_dialog_through_command_guarded(".uno:EditRegion") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:EditRegion") as xDialog:
xHide = xDialog.getChild('hide')
self.assertEqual('false', get_state_as_dict(xHide)['Selected'])
@@ -42,7 +42,7 @@ class tdf140863(UITestCase):
self.assertFalse(document.TextSections.Section1.IsVisible)
self.assertEqual(get_state_as_dict(xWriterEdit)["CurrentPage"], "1")
- with self.ui_test.execute_dialog_through_command_guarded(".uno:EditRegion") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:EditRegion") as xDialog:
xHide = xDialog.getChild('hide')
self.assertEqual('true', get_state_as_dict(xHide)['Selected'])
diff --git a/sw/qa/uitest/writer_tests7/tdf141557.py b/sw/qa/uitest/writer_tests7/tdf141557.py
index 0a15db24dd50..820505f2f43f 100644
--- a/sw/qa/uitest/writer_tests7/tdf141557.py
+++ b/sw/qa/uitest/writer_tests7/tdf141557.py
@@ -23,7 +23,7 @@ class tdf141557(UITestCase):
self.ui_test.wait_until_child_is_available('metricfield')
- with self.ui_test.execute_dialog_through_command_guarded(".uno:TransformDialog") as xDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:TransformDialog") as xDialog:
xDialog.getChild('topara').executeAction("CLICK", tuple())
diff --git a/sw/qa/uitest/writer_tests7/tdf46561.py b/sw/qa/uitest/writer_tests7/tdf46561.py
index 41acea93ed16..0eb14bc613c3 100644
--- a/sw/qa/uitest/writer_tests7/tdf46561.py
+++ b/sw/qa/uitest/writer_tests7/tdf46561.py
@@ -37,7 +37,7 @@ class tdf46561(UITestCase):
# Switch "same left and right page headers" on and off a few times
for _ in range(4):
- with self.ui_test.execute_dialog_through_command_guarded(".uno:PageDialog") as PageDialog:
+ with self.ui_test.execute_dialog_through_command(".uno:PageDialog") as PageDialog:
xTabs = PageDialog.getChild("tabcontrol")
select_pos(xTabs, "4")
diff --git a/sw/qa/uitest/writer_tests7/tdf90401.py b/sw/qa/uitest/writer_tests7/tdf90401.py
index fd8c9b91b135..40b9b483153f 100644
--- a/sw/qa/uitest/writer_tests7/tdf90401.py
+++ b/sw/qa/uitest/writer_tests7/tdf90401.py
@@ -30,7 +30,7 @@ class tdf90401(UITestCase):
# enable remove personal info security option
- with self.ui_test.execute_dialog_through_command_guarded('.uno:OptionsTreeDialog', close_button="") as xDialog:
+ with self.ui_test.execute_dialog_through_command('.uno:OptionsTreeDialog', close_button="") as xDialog:
xPages = xDialog.getChild('pages')
xGenEntry = xPages.getChild('0')
xSecurityPage = xGenEntry.getChild('6')
@@ -55,7 +55,7 @@ class tdf90401(UITestCase):
xFilePath = os.path.join(tempdir, 'tdf90401-tmp.fodt')
# Save Copy as
- with self.ui_test.execute_dialog_through_command_guarded('.uno:SaveAs', close_button="open") as xDialog:
+ with self.ui_test.execute_dialog_through_command('.uno:SaveAs', close_button="open") as xDialog:
xFileName = xDialog.getChild('file_name')
xFileName.executeAction('TYPE', mkPropertyValues({'KEYCODE':'CTRL+A'}))
xFileName.executeAction('TYPE', mkPropertyValues({'KEYCODE':'BACKSPACE'}))