summaryrefslogtreecommitdiff
path: root/uitest/demo_ui
diff options
context:
space:
mode:
Diffstat (limited to 'uitest/demo_ui')
-rw-r--r--uitest/demo_ui/edit.py5
-rw-r--r--uitest/demo_ui/spinfield.py4
2 files changed, 4 insertions, 5 deletions
diff --git a/uitest/demo_ui/edit.py b/uitest/demo_ui/edit.py
index a40677c5d8ae..5eff4e0fad90 100644
--- a/uitest/demo_ui/edit.py
+++ b/uitest/demo_ui/edit.py
@@ -8,6 +8,7 @@
from libreoffice.uno.propertyvalue import mkPropertyValues
from uitest.framework import UITestCase
+from uitest.uihelper.common import type_text
class EditTest(UITestCase):
@@ -20,9 +21,7 @@ class EditTest(UITestCase):
xEdit = xAddNameDlg.getChild("edit")
- props = {"TEXT": "simpleRangeName"}
- actionProps = mkPropertyValues(props)
- xEdit.executeAction("TYPE", actionProps)
+ type_text(xEdit, "simpleRangeName")
xAddBtn = xAddNameDlg.getChild("cancel")
xAddBtn.executeAction("CLICK", tuple())
diff --git a/uitest/demo_ui/spinfield.py b/uitest/demo_ui/spinfield.py
index 49952dcb4cfa..c093cf5d4d7c 100644
--- a/uitest/demo_ui/spinfield.py
+++ b/uitest/demo_ui/spinfield.py
@@ -6,9 +6,9 @@
#
from libreoffice.uno.propertyvalue import mkPropertyValues
-from uitest.uihelper.common import get_state_as_dict
from uitest.framework import UITestCase
+from uitest.uihelper.common import get_state_as_dict, type_text
class SpinFieldTest(UITestCase):
@@ -68,7 +68,7 @@ class SpinFieldTest(UITestCase):
xCellsDlg = self.xUITest.getTopFocusWindow()
xDecimalPlaces = xCellsDlg.getChild("leadzerosed")
- xDecimalPlaces.executeAction("TYPE", mkPropertyValues({"TEXT": "4"}))
+ type_text(xDecimalPlaces, "4")
decimal_places_state = get_state_as_dict(xDecimalPlaces)
assert(decimal_places_state["Text"] == "41")