sw/qa/extras/uiwriter/uiwriter2.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit b710b4fa9f243e81c905567bb6712ceb96a56943 Author: Miklos Vajna <vmik...@collabora.com> AuthorDate: Thu Sep 26 16:53:07 2019 +0200 Commit: Miklos Vajna <vmik...@collabora.com> CommitDate: Thu Sep 26 20:46:47 2019 +0200 CppunitTest_sw_uiwriter: improve limit in testTdf105330 The problem was that the cursor was invisible. I thought that we can assert that the cursor height is 12pt + the linespacing (276 twips), but turns out the exact value is subject to pixel-alignment, so it's not a good test to require equality. Instead, make sure that the height is at least the 12pt, which is explicitly defined in the document. That fails without the fix, and is a saner limit. Change-Id: I4f9f512542cefc6fa20d6fdf02e9eb5d2e1c1d5e Reviewed-on: https://gerrit.libreoffice.org/79636 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmik...@collabora.com> diff --git a/sw/qa/extras/uiwriter/uiwriter2.cxx b/sw/qa/extras/uiwriter/uiwriter2.cxx index 5ac978713b17..fd9bee5280d7 100644 --- a/sw/qa/extras/uiwriter/uiwriter2.cxx +++ b/sw/qa/extras/uiwriter/uiwriter2.cxx @@ -2247,10 +2247,10 @@ CPPUNIT_TEST_FIXTURE(SwUiWriterTest2, testTdf105330) sw::UndoManager& rUndoManager = pDoc->GetUndoManager(); rUndoManager.Undo(); - // Without the accompanying fix in place, height was only 1 twips (practically invisible), with - // the fix in place it is seen to be either 271 or 276 for different builds: + // Without the accompanying fix in place, height was only 1 twips (practically invisible). + // Require at least 12pt height (font size under the cursor), in twips. CPPUNIT_ASSERT_GREATEREQUAL( - static_cast<long>(271), + static_cast<long>(240), pWrtShell->GetVisibleCursor()->GetTextCursor().GetSize().getHeight()); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits