sw/qa/extras/ooxmlexport/data/tdf156484.docx |binary sw/qa/extras/ooxmlexport/ooxmlexport13.cxx | 14 ++++++++++++++ 2 files changed, 14 insertions(+)
New commits: commit b27a39e26bdb1178c6d6a3f6880b9d40a1f9b1ab Author: Xisco Fauli <xiscofa...@libreoffice.org> AuthorDate: Fri May 10 12:33:40 2024 +0200 Commit: Xisco Fauli <xiscofa...@libreoffice.org> CommitDate: Fri May 10 14:08:41 2024 +0200 tdf#156484: sw_ooxmlexport13: Add unittest Change-Id: I3bcda136eff62a61783b4e52132125c4b1794ccb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167446 Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org> Tested-by: Jenkins diff --git a/sw/qa/extras/ooxmlexport/data/tdf156484.docx b/sw/qa/extras/ooxmlexport/data/tdf156484.docx new file mode 100644 index 000000000000..73a61738f681 Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf156484.docx differ diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx index 9f0420354e9b..281981e9a51a 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport13.cxx @@ -711,6 +711,20 @@ DECLARE_OOXMLEXPORT_TEST(testTdf119201, "tdf119201.docx") CPPUNIT_ASSERT_MESSAGE("Third shape should be printable.", getProperty<bool>(xShape, "Printable")); } +DECLARE_OOXMLEXPORT_TEST(testTdf156484, "tdf156484.docx") +{ + auto xShape(getShape(1)); + // Without the fix in place, this test would have failed here + CPPUNIT_ASSERT_MESSAGE("First shape should not be visible.", !getProperty<bool>(xShape, "Visible")); + CPPUNIT_ASSERT_MESSAGE("First shape should not be printable.", !getProperty<bool>(xShape, "Printable")); + xShape = getShape(2); + CPPUNIT_ASSERT_MESSAGE("Second shape should not be visible.", !getProperty<bool>(xShape, "Visible")); + CPPUNIT_ASSERT_MESSAGE("Second shape should not be printable.", !getProperty<bool>(xShape, "Printable")); + xShape = getShape(3); + CPPUNIT_ASSERT_MESSAGE("Third shape should not be visible.", !getProperty<bool>(xShape, "Visible")); + CPPUNIT_ASSERT_MESSAGE("Third shape should not be printable.", !getProperty<bool>(xShape, "Printable")); +} + DECLARE_OOXMLEXPORT_TEST(testTdf124594, "tdf124594.docx") { xmlDocUniquePtr pDump = parseLayoutDump();