diff options
author | Miklos Vajna <vmiklos@suse.cz> | 2013-03-26 11:15:59 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@suse.cz> | 2013-03-26 15:21:11 +0100 |
commit | 7329df74df134a77d078f47d5c8b70d54c5d1edb (patch) | |
tree | 0cb134f80a3cf10e472be78247ef6514d5b8eef8 /sw | |
parent | bnc#780645 testcase: missing <w:tblLayout w:type=fixed/> (diff) | |
download | core-7329df74df134a77d078f47d5c8b70d54c5d1edb.tar.gz core-7329df74df134a77d078f47d5c8b70d54c5d1edb.zip |
fdo#59273 import w:tblLayout of DOCX tables
Change-Id: I9af50a4c176168e2794eaa9b0e8eaeb6b9d06b13
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/extras/ooxmlimport/data/fdo59273.docx | bin | 0 -> 4358 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlimport/ooxmlimport.cxx | 12 |
2 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlimport/data/fdo59273.docx b/sw/qa/extras/ooxmlimport/data/fdo59273.docx Binary files differnew file mode 100644 index 000000000000..fcdfd7734411 --- /dev/null +++ b/sw/qa/extras/ooxmlimport/data/fdo59273.docx diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index a5b41e3a564e..e3f161838a5f 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -122,6 +122,7 @@ public: void testFdo61343(); void testToolsLineNumbering(); void testFdo60922(); + void testFdo59273(); CPPUNIT_TEST_SUITE(Test); #if !defined(MACOSX) && !defined(WNT) @@ -195,6 +196,7 @@ void Test::run() {"fdo61343.docx", &Test::testFdo61343}, {"tools-line-numbering.docx", &Test::testToolsLineNumbering}, {"fdo60922.docx", &Test::testFdo60922}, + {"fdo59273.docx", &Test::testFdo59273}, }; header(); for (unsigned int i = 0; i < SAL_N_ELEMENTS(aMethods); ++i) @@ -1288,6 +1290,16 @@ void Test::testFdo60922() CPPUNIT_ASSERT_EQUAL(sal_Int32(100), getProperty<sal_Int32>(getRun(getParagraph(1), 1), "CharEscapementHeight")); } +void Test::testFdo59273() +{ + uno::Reference<text::XTextTablesSupplier> xTablesSupplier(mxComponent, uno::UNO_QUERY); + uno::Reference<container::XIndexAccess> xTables(xTablesSupplier->getTextTables( ), uno::UNO_QUERY); + uno::Reference<text::XTextTable> xTextTable(xTables->getByIndex(0), uno::UNO_QUERY); + uno::Reference<table::XTableRows> xTableRows(xTextTable->getRows(), uno::UNO_QUERY); + // Was 9997, so the 4th column had ~zero width + CPPUNIT_ASSERT_EQUAL(sal_Int16(7498), getProperty< uno::Sequence<text::TableColumnSeparator> >(xTableRows->getByIndex(0), "TableColumnSeparators")[2].Position); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT(); |