diff --git a/autotests/texthandlertest.cpp b/autotests/texthandlertest.cpp index 511dd2c5b..a9ea8592f 100644 --- a/autotests/texthandlertest.cpp +++ b/autotests/texthandlertest.cpp @@ -40,6 +40,7 @@ private Q_SLOTS: void stripDisallowedTags(); void stripDisallowedAttributes(); void emptyCodeTags(); + void formatBlockQuote(); void sendSimpleStringCase(); void sendSingleParaMarkup(); @@ -146,6 +147,16 @@ void TextHandlerTest::emptyCodeTags() QCOMPARE(testTextHandler.handleRecieveRichText(), testOutputString); } +void TextHandlerTest::formatBlockQuote() +{ + auto input = QStringLiteral("
\n"); + auto expectedOutput = QStringLiteral("Lorem Ispum
\n
"); + + TextHandler testTextHandler; + testTextHandler.setData(input); + QCOMPARE(testTextHandler.handleRecieveRichText(), expectedOutput); +} + void TextHandlerTest::sendSimpleStringCase() { const QString testInputString = QStringLiteral("This data should just be put in a paragraph."); @@ -458,8 +469,9 @@ void TextHandlerTest::receiveRichEdited_data() QTest::newRow("basic") << QStringLiteral("Edited") << QStringLiteral("Edited (edited)"); QTest::newRow("multiple paragraphs") << QStringLiteral("
\u201CLorem Ispum\u201D
Edited
\nEdited
") << QStringLiteral("Edited
\nEdited (edited)
"); - QTest::newRow("blockquote") << QStringLiteral("Edited") - << QStringLiteral("
Edited
(edited)
"); + QTest::newRow("blockquote") + << QStringLiteral("Edited") + << QStringLiteral("
\u201CEdited\u201D
(edited)
"); } void TextHandlerTest::receiveRichEdited()