diff options
author | Justin Luth <justin_luth@sil.org> | 2018-07-16 20:55:33 +0300 |
---|---|---|
committer | Justin Luth <justin_luth@sil.org> | 2018-07-21 21:37:18 +0200 |
commit | 6b7f12f6108f136d60bd77e3787ef6a2632038cd (patch) | |
tree | ba776afea901977cc585c317c787f5d5eea0c023 /sw/qa/extras/ooxmlexport | |
parent | 71821a74d65765afa9f2273d98b5b0cc3ac2782f (diff) |
writerfilter: default style is the last one
Documentation states, and the examples confirm that
"If this attribute (w:default) is specified by multiple styles, then
the last instance of a style with this property shall be used."
Change-Id: I17f06ab8944a39341a00c479117e978a01d6af7a
Reviewed-on: https://gerrit.libreoffice.org/57510
Tested-by: Jenkins
Reviewed-by: Justin Luth <justin_luth@sil.org>
Diffstat (limited to 'sw/qa/extras/ooxmlexport')
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/defaultStyle.docx | bin | 0 -> 5126 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport11.cxx | 6 |
2 files changed, 6 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/defaultStyle.docx b/sw/qa/extras/ooxmlexport/data/defaultStyle.docx Binary files differnew file mode 100644 index 000000000000..8e3faa70da8c --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/defaultStyle.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx index 3246fe5eec4d..b4d6dad88132 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx @@ -150,6 +150,12 @@ DECLARE_OOXMLEXPORT_TEST(testTdf116410, "tdf116410.docx") CPPUNIT_ASSERT_EQUAL(1, getPages()); } +DECLARE_OOXMLEXPORT_TEST(testDefaultStyle, "defaultStyle.docx") +{ + CPPUNIT_ASSERT_EQUAL_MESSAGE( "Default Style", OUString("Title"), getProperty<OUString>(getParagraph(1), "ParaStyleName") ); + CPPUNIT_ASSERT_EQUAL(2, getPages()); +} + DECLARE_OOXMLEXPORT_TEST(testParagraphSplitOnSectionBorder, "parasplit-on-section-border.odt") { xmlDocPtr pXmlDoc = parseExport("word/document.xml"); |