Debian Codegraph @

sw/qa/uitest/writer_tests8/tdf141557.py

raw symbols SCIP
1 # -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
2 #
3 # This file is part of the LibreOffice project.
4 #
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 #
9 from uitest.framework import UITestCase
10 from com.sun.star.text.TextContentAnchorType import AS_CHARACTER, AT_PARAGRAPH
11 from uitest.uihelper.common import get_url_for_data_file
12
13 class tdf141557(UITestCase):
14 def test_tdf141557(self):
15 # load the sample file
16 with self.ui_test.load_file(get_url_for_data_file("tdf141557.docx")):
17 document = self.ui_test.get_component()
18
19 self.assertEqual(AS_CHARACTER, document.DrawPage[0].AnchorType)
20
21 self.xUITest.executeCommand(".uno:JumpToNextFrame")
22
23 self.ui_test.wait_until_child_is_available('metricfield')
24
25 with self.ui_test.execute_dialog_through_command(".uno:TransformDialog") as xDialog:
26
27
28 xDialog.getChild('topara').executeAction("CLICK", tuple())
29
30
31 # Without the fix in place, at this point crash occurs.
32 self.assertEqual(AT_PARAGRAPH, document.DrawPage[0].AnchorType)
33
34 # vim: set shiftwidth=4 softtabstop=4 expandtab: