[Libreoffice-commits] core.git: Branch 'distro/collabora/co-2021' - sc/qa
Dennis Francis (via logerrit)
logerrit at kemper.freedesktop.org
Wed Aug 18 18:28:40 UTC 2021
sc/qa/unit/data/xlsx/escape-unicode.xlsx |binary
sc/qa/unit/subsequent_filters-test.cxx | 13 +++++++++++++
2 files changed, 13 insertions(+)
New commits:
commit 40ae81c588fdaf8b102b70e906b74db3d796f379
Author: Dennis Francis <dennis.francis at collabora.com>
AuthorDate: Wed Aug 18 11:51:07 2021 +0530
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Wed Aug 18 20:28:02 2021 +0200
tdf#118470: unit test for escaped unicode chars in strings import
Conflicts:
sc/qa/unit/subsequent_filters-test.cxx
Change-Id: I4c4190538bdcb3292546d6d5884eb7900807060c
Signed-off-by: Dennis Francis <dennis.francis at collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120664
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Andras Timar <andras.timar at collabora.com>
diff --git a/sc/qa/unit/data/xlsx/escape-unicode.xlsx b/sc/qa/unit/data/xlsx/escape-unicode.xlsx
new file mode 100644
index 000000000000..ec43688b74b8
Binary files /dev/null and b/sc/qa/unit/data/xlsx/escape-unicode.xlsx differ
diff --git a/sc/qa/unit/subsequent_filters-test.cxx b/sc/qa/unit/subsequent_filters-test.cxx
index dd4c722145ca..8f558b4e7f3f 100644
--- a/sc/qa/unit/subsequent_filters-test.cxx
+++ b/sc/qa/unit/subsequent_filters-test.cxx
@@ -300,6 +300,7 @@ public:
void testDeleteCirclesInRowAndCol();
void testTdf129940();
void testTdf139763ShapeAnchor();
+ void testEscapedUnicodeXLSX();
CPPUNIT_TEST_SUITE(ScFiltersTest);
CPPUNIT_TEST(testCondFormatOperatorsSameRangeXLSX);
@@ -485,6 +486,7 @@ public:
CPPUNIT_TEST(testDeleteCirclesInRowAndCol);
CPPUNIT_TEST(testTdf129940);
CPPUNIT_TEST(testTdf139763ShapeAnchor);
+ CPPUNIT_TEST(testEscapedUnicodeXLSX);
CPPUNIT_TEST_SUITE_END();
@@ -5456,6 +5458,17 @@ void ScFiltersTest::testTdf139763ShapeAnchor()
xDocSh->DoClose();
}
+void ScFiltersTest::testEscapedUnicodeXLSX()
+{
+ ScDocShellRef xDocSh = loadDoc("escape-unicode.", FORMAT_XLSX);
+ ScDocument& rDoc = xDocSh->GetDocument();
+
+ // Without the fix, there would be "_x000D_" after every new-line char.
+ CPPUNIT_ASSERT_EQUAL(OUString("Line 1\nLine 2\nLine 3\nLine 4"), rDoc.GetString(1, 1, 0));
+
+ xDocSh->DoClose();
+}
+
ScFiltersTest::ScFiltersTest()
: ScBootstrapFixture( "sc/qa/unit/data" )
{
More information about the Libreoffice-commits
mailing list