sw/qa/uitest/writer_tests4/spellDialog.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)
New commits: commit 81163c384364e4b5c99392b76f027f8c2b87c259 Author: László Németh <nem...@numbertext.org> AuthorDate: Thu Jan 5 11:09:06 2023 +0100 Commit: László Németh <nem...@numbertext.org> CommitDate: Thu Jan 5 14:42:10 2023 +0000 tdf#65535 sw spellDialog.py: fix lo-upsan build better Follow-up to commit d2614337e8291b9b6d114fda5ae914f6940c353a "tdf#65535 sw spellDialog.py: add same latency to fix lo-upsan build". Change-Id: Ibb7e5e4afe1cab99fc24342afb94458f612ec3f7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/145073 Tested-by: Jenkins Reviewed-by: László Németh <nem...@numbertext.org> diff --git a/sw/qa/uitest/writer_tests4/spellDialog.py b/sw/qa/uitest/writer_tests4/spellDialog.py index 9fd9d16cee74..2c84f03f8ec9 100644 --- a/sw/qa/uitest/writer_tests4/spellDialog.py +++ b/sw/qa/uitest/writer_tests4/spellDialog.py @@ -7,7 +7,7 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. # -import re +import re, time from uitest.framework import UITestCase from uitest.uihelper.common import get_state_as_dict, get_url_for_data_file from uitest.uihelper.common import type_text @@ -220,8 +220,8 @@ frog, dogg, catt""" # type a bad word after the word with comment cursor.goRight(5, False) - type_text(xEdit, " baad") - cursor.goLeft(10, False) + type_text(xEdit, " baad ") + cursor.goLeft(11, False) # fix the first word using the spelling dialog with self.ui_test.execute_modeless_dialog_through_command(".uno:SpellingAndGrammarDialog", close_button="close") as xDialog: @@ -233,12 +233,12 @@ frog, dogg, catt""" change = xDialog.getChild('change') change.executeAction("CLICK", ()) - # fix UPSAN build - import time - time.sleep(0.2) + fixed_word = "Bad baad " + while fixed_word != document.Text.getString(): + time.sleep(0.1) output_text = document.Text.getString() - self.assertEqual("Bad baad", output_text) + self.assertEqual(fixed_word, output_text) # check the original comment has_comment = False