Version 7.6.3.2-android, tag libreoffice-7.6.3.2-android
[LibreOffice.git] / sd / qa / uitest / impress_tests2 / tdf144943.py
blob9bf5a891fb34415909452f406ebb593061385f1d
1 # -*- tab-width: 4; indent-tabs-mode: nil; py-indent-offset: 4 -*-
3 # This file is part of the LibreOffice project.
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/.
9 from uitest.framework import UITestCase
10 from uitest.uihelper.common import get_url_for_data_file
11 from libreoffice.uno.propertyvalue import mkPropertyValues
13 #Bug 144943 - FILEOPEN PPTX Read-only passwords on PPTX files are not working
15 class tdf144943(UITestCase):
17 def test_tdf144943(self):
18 with self.ui_test.load_file(get_url_for_data_file("tdf144943.pptx")):
19 document = self.ui_test.get_component()
21 # Without the fix in place, this test would have failed with
22 # AssertionError: False is not true
23 self.assertTrue(document.isReadonly())
25 with self.ui_test.execute_dialog_through_command(".uno:EditDoc") as xDialog:
26 xPassword = xDialog.getChild("newpassEntry")
27 xPassword.executeAction("TYPE", mkPropertyValues({"TEXT": "password"}))
29 self.assertFalse(document.isReadonly())
31 # vim: set shiftwidth=4 softtabstop=4 expandtab: