related: tdf#129032: uitest: check ok button is disabled

Change-Id: I56c7a4736ad7beda15bf5d93e492952ccb4bd1bb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110272
Tested-by: Xisco Fauli <xiscofauli@libreoffice.org>
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
diff --git a/sd/qa/uitest/impress_tests/renameSlide.py b/sd/qa/uitest/impress_tests/renameSlide.py
index 964f6a7..7393a41 100644
--- a/sd/qa/uitest/impress_tests/renameSlide.py
+++ b/sd/qa/uitest/impress_tests/renameSlide.py
@@ -7,9 +7,6 @@
from uitest.framework import UITestCase
from libreoffice.uno.propertyvalue import mkPropertyValues
from uitest.uihelper.common import get_state_as_dict
import time
from uitest.debug import sleep
from uitest.uihelper.common import select_pos

class renameSlide(UITestCase):

@@ -37,5 +34,21 @@ class renameSlide(UITestCase):
        xOKBtn = xDialog.getChild("ok")
        self.ui_test.close_dialog_through_button(xOKBtn)

        self.xUITest.executeCommand(".uno:InsertPage")

        self.ui_test.execute_dialog_through_command(".uno:RenamePage")
        xDialog = self.xUITest.getTopFocusWindow()

        xOKBtn = xDialog.getChild("ok")
        self.assertEqual("true", get_state_as_dict(xOKBtn)['Enabled'])

        name_entry = xDialog.getChild("name_entry")
        name_entry.executeAction("TYPE", mkPropertyValues({"TEXT":"NewName"}))

        self.assertEqual("false", get_state_as_dict(xOKBtn)['Enabled'])

        xCancelBtn = xDialog.getChild("cancel")
        self.ui_test.close_dialog_through_button(xCancelBtn)

        self.ui_test.close_doc()
# vim: set shiftwidth=4 softtabstop=4 expandtab: