diff options
Diffstat (limited to 'tests/auto')
3 files changed, 6 insertions, 6 deletions
diff --git a/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp b/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp index b8d53ca194..686187cc77 100644 --- a/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp +++ b/tests/auto/gui/text/qtextmarkdownimporter/tst_qtextmarkdownimporter.cpp @@ -380,7 +380,7 @@ void tst_QTextMarkdownImporter::avoidBlankLineAtBeginning_data() QTest::newRow("Text block") << QString("Markdown text") << 1; QTest::newRow("Headline") << QString("Markdown text\n============") << 1; - QTest::newRow("Code block") << QString(" Markdown text") << 2; + QTest::newRow("Code block") << QString(" Markdown text") << 1; QTest::newRow("Unordered list") << QString("* Markdown text") << 1; QTest::newRow("Ordered list") << QString("1. Markdown text") << 1; QTest::newRow("Blockquote") << QString("> Markdown text") << 1; @@ -501,18 +501,17 @@ void tst_QTextMarkdownImporter::fencedCodeBlocks_data() QTest::addColumn<QString>("expectedFenceChar"); QTest::addColumn<QString>("rewrite"); - // TODO shouldn't add empty blocks: QTBUG-101031 QTest::newRow("backtick fence with language") << "```pseudocode\nprint('hello world\\n')\n```\n" - << 2 << 0 << "pseudocode" << "`" + << 1 << 0 << "pseudocode" << "`" << "```pseudocode\nprint('hello world\\n')\n```\n\n"; QTest::newRow("tilde fence with language") << "~~~pseudocode\nprint('hello world\\n')\n~~~\n" - << 2 << 0 << "pseudocode" << "~" + << 1 << 0 << "pseudocode" << "~" << "~~~pseudocode\nprint('hello world\\n')\n~~~\n\n"; QTest::newRow("embedded backticks") << "```\nnone `one` ``two``\n```\nplain\n```\n```three``` ````four````\n```\nplain\n" - << 4 << 2 << QString() << "`" + << 2 << 2 << QString() << "`" << "```\nnone `one` ``two``\n```\nplain\n\n```\n```three``` ````four````\n```\nplain\n\n"; } diff --git a/tests/auto/gui/text/qtextmarkdownwriter/data/blockquotes.md b/tests/auto/gui/text/qtextmarkdownwriter/data/blockquotes.md index 702ccef134..b29b53651b 100644 --- a/tests/auto/gui/text/qtextmarkdownwriter/data/blockquotes.md +++ b/tests/auto/gui/text/qtextmarkdownwriter/data/blockquotes.md @@ -50,6 +50,7 @@ Now let's have an indented code block: } and end with a fenced code block: + ~~~pseudocode #include <something.h> #include <else.h> diff --git a/tests/auto/gui/text/qtextmarkdownwriter/tst_qtextmarkdownwriter.cpp b/tests/auto/gui/text/qtextmarkdownwriter/tst_qtextmarkdownwriter.cpp index c5e4829533..b258869dfd 100644 --- a/tests/auto/gui/text/qtextmarkdownwriter/tst_qtextmarkdownwriter.cpp +++ b/tests/auto/gui/text/qtextmarkdownwriter/tst_qtextmarkdownwriter.cpp @@ -494,7 +494,7 @@ void tst_QTextMarkdownWriter::fromHtml_data() "![foo](/url \"title\")\n\n"; QTest::newRow("code") << "<pre class=\"language-pseudocode\">\n#include \"foo.h\"\n\nblock {\n statement();\n}\n\n</pre>" << - "```pseudocode\n#include \"foo.h\"\n\nblock {\n statement();\n}\n```\n\n"; + "```pseudocode\n#include \"foo.h\"\n\nblock {\n statement();\n}\n\n```\n\n"; // TODO // QTest::newRow("escaped number and paren after double newline") << // "<p>(The first sentence of this paragraph is a line, the next paragraph has a number</p>13) but that's not part of an ordered list" << |