| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
from uitest.framework import UITestCase |
| 11 |
from uitest.uihelper.common import get_state_as_dict, type_text |
| 12 |
from uitest.uihelper.common import select_pos |
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
class tdf122722(UITestCase): |
| 17 |
def test_tdf122722_format_character_hidden(self): |
| 18 |
with self.ui_test.create_doc_in_start_center("writer") as document: |
| 19 |
xWriterDoc = self.xUITest.getTopFocusWindow() |
| 20 |
xWriterEdit = xWriterDoc.getChild("writer_edit") |
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
type_text(xWriterEdit, "LibreOffice") |
| 25 |
|
| 26 |
self.xUITest.executeCommand(".uno:SelectAll") |
| 27 |
self.assertEqual(document.Text.String[0:11], "LibreOffice") |
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
|
| 32 |
with self.ui_test.execute_dialog_through_command(".uno:FontDialog") as xDialog: |
| 33 |
xTabs = xDialog.getChild("tabcontrol") |
| 34 |
select_pos(xTabs, "1") |
| 35 |
|
| 36 |
xHidden = xDialog.getChild("hiddencb") |
| 37 |
|
| 38 |
xHidden.executeAction("CLICK", tuple()) |
| 39 |
|
| 40 |
|
| 41 |
with self.ui_test.execute_dialog_through_command(".uno:FontDialog") as xDialog: |
| 42 |
xTabs = xDialog.getChild("tabcontrol") |
| 43 |
select_pos(xTabs, "1") |
| 44 |
|
| 45 |
xHidden = xDialog.getChild("hiddencb") |
| 46 |
|
| 47 |
self.assertEqual(get_state_as_dict(xHidden)["Selected"], "true") |
| 48 |
xHidden.executeAction("CLICK", tuple()) |
| 49 |
|
| 50 |
|
| 51 |
self.assertEqual(document.Text.String[0:11], "LibreOffice") |
| 52 |
|
| 53 |
|