sc/qa/unit/jumbosheets-test.cxx | 8 ++++++++ 1 file changed, 8 insertions(+)
New commits: commit c5bed7889fe391e0e408248c2db042b5e489bcda Author: Mike Kaganski <mike.kagan...@collabora.com> AuthorDate: Thu Sep 8 15:42:40 2022 +0300 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Thu Sep 8 16:11:22 2022 +0200 Fix CppunitTest_sc_jumbosheets_test on non-default DPI Change-Id: I067622274cfa7518462ad74015dc3942f35b6b9c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139675 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/sc/qa/unit/jumbosheets-test.cxx b/sc/qa/unit/jumbosheets-test.cxx index e3ae57564499..81151b9ecefa 100644 --- a/sc/qa/unit/jumbosheets-test.cxx +++ b/sc/qa/unit/jumbosheets-test.cxx @@ -255,6 +255,14 @@ void ScJumboSheetsTest::testTdf134553() // Without the fix in place, this test would have failed here CPPUNIT_ASSERT(pOleObj); + // Sorry, the charts so severely suffer from DPI dependency, that I can't find motivation + // to add huge tolerances (around 350!) here to make it pass on non-default DPI, with no + // guarantee that the test would have any value after that. So just skip it. + // FIXME: the DPI check should be removed when either (1) the test is fixed to work with + // non-default DPI; or (2) unit tests on Windows are made to use svp VCL plugin. + if (!IsDefaultDPI()) + return; + CPPUNIT_ASSERT_EQUAL(tools::Long(12741), pOleObj->GetLogicRect().getOpenWidth()); CPPUNIT_ASSERT_EQUAL(tools::Long(7620), pOleObj->GetLogicRect().getOpenHeight()); CPPUNIT_ASSERT_EQUAL(tools::Long(4574), pOleObj->GetLogicRect().getX());