| 1 |
{ |
| 2 |
"0. includeonly around the entire attribute": { |
| 3 |
"html2wt": "<span id=\"v2\">bar</span>\n" |
| 4 |
}, |
| 5 |
"1. Entities and nowikis inside templated attributes should be handled correctly": { |
| 6 |
"wt2html": "<div style=\"background:#f9f9f9;\" about=\"#mwt3\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"dsr\":[0,57,48,6]}' data-mw='{\"attribs\":[[{\"txt\":\"style\",\"html\":\"<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"}]],\\\"dsr\\\":[5,47,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"1x\\\",\\\"href\\\":\\\"./Template:1x\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"style{{=}}\\\\\\\"background:&amp;#35;f9f9f9;\\\\\\\"\\\"}},\\\"i\\\":0}}]}'>style=\\\"background:</span><span typeof=\\\"mw:Entity\\\" about=\\\"#mwt1\\\" data-parsoid='{\\\"src\\\":\\\"&amp;#35;\\\",\\\"srcContent\\\":\\\"#\\\"}'>#</span><span about=\\\"#mwt1\\\" data-parsoid=\\\"{}\\\">f9f9f9;\\\"</span>\"},{\"html\":\"\"}]]}'>foo</div>", |
| 7 |
"html2html": "<div style=\"background:#f9f9f9;\" about=\"#mwt3\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"dsr\":[0,57,48,6]}' data-mw='{\"attribs\":[[{\"txt\":\"style\",\"html\":\"<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"}]],\\\"dsr\\\":[5,47,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"1x\\\",\\\"href\\\":\\\"./Template:1x\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"style{{=}}\\\\\\\"background:&amp;#35;f9f9f9;\\\\\\\"\\\"}},\\\"i\\\":0}}]}'>style=\\\"background:</span><span typeof=\\\"mw:Entity\\\" about=\\\"#mwt1\\\" data-parsoid='{\\\"src\\\":\\\"&amp;#35;\\\",\\\"srcContent\\\":\\\"#\\\"}'>#</span><span about=\\\"#mwt1\\\" data-parsoid=\\\"{}\\\">f9f9f9;\\\"</span>\"},{\"html\":\"\"}]]}'>foo</div>" |
| 8 |
}, |
| 9 |
"1. Lists with start-of-line-transparent tokens before bullets: Comments": { |
| 10 |
"html2wt": "* foo\n* <!--cmt-->bar\n<!--cmt-->* baz" |
| 11 |
}, |
| 12 |
"1. Nested mixed wikitext and html list": { |
| 13 |
"html2wt": "* hi\n* <ul><li>ho</li></ul>\n* hi\n** ho\n" |
| 14 |
}, |
| 15 |
"1. Table tag in SOL posn. should get reparsed correctly with valid TSR": { |
| 16 |
"wt2wt": "{{1x|}}\n{| width=\"100%\"\n|foo\n|}", |
| 17 |
"selser [0,[0,3]]": "{{1x|}}{| width = '100%'\n|}", |
| 18 |
"selser [0,[0,[0,2]]]": "{{1x|}}{| width = '100%'\n|foo<!--1lo6yer-->\n|}", |
| 19 |
"selser [0,1]": "{{1x|}}{| width=\"100%\" data-foobar=\"d5ck45\"\n|foo\n|}", |
| 20 |
"selser [0,[0,[[[2]],3]]]": "{{1x|}}{| width = '100%'\n|1lr4bk8foo\n|}", |
| 21 |
"selser [0,[4,[4,2]]]": "{{1x|}}{| width = '100%'<!--1p4haoj--><!--1ifk60g--><!--1tu056n-->\n|}", |
| 22 |
"selser [0,[4,[2,0]]]": "{{1x|}}{| width = '100%'<!--hxenqc--><!--xbh46y-->\n|foo\n|}", |
| 23 |
"selser [0,[4,[3,0]]]": "{{1x|}}{| width = '100%'<!--qmxjva-->\n|}", |
| 24 |
"selser [0,2]": "{{1x|}}16d54ej\n{| width = '100%'\n|foo\n|}", |
| 25 |
"selser [0,[4,[[1],4]]]": "{{1x|}}{| width = '100%'<!--rsu6we-->\n| data-foobar=\"1qt3mgp\" |foo<!--1n7ytsm-->\n|}", |
| 26 |
"selser [0,[0,1]]": "{{1x|}}{| width = '100%'\n|foo\n|}", |
| 27 |
"selser [0,[0,[[3],0]]]": "{{1x|}}{| width = '100%'\n\n|}", |
| 28 |
"selser [0,[0,[1,4]]]": "{{1x|}}{| width = '100%'\n|foo<!--12a4fih-->\n|}", |
| 29 |
"selser [0,[0,[[3],3]]]": "{{1x|}}{| width = '100%'\n|}", |
| 30 |
"selser [0,[0,[2,0]]]": "{{1x|}}{| width = '100%'\n<!--19woy9y-->|foo\n|}", |
| 31 |
"selser [0,[0,[[[3]],3]]]": "{{1x|}}{| width = '100%'\n|\n|}", |
| 32 |
"selser [0,[0,[4,0]]]": "{{1x|}}{| width = '100%'\n<!--19hnpm1-->\n|}", |
| 33 |
"selser [0,[3,[1,0]]]": "{{1x|}}{| width = '100%'\n|foo\n|}", |
| 34 |
"selser [0,[0,[[1],4]]]": "{{1x|}}{| width = '100%'\n| data-foobar=\"bz5rz9\" |foo<!--4qz9ay-->\n|}" |
| 35 |
}, |
| 36 |
"1. Template wrapping shouldn't ignore fostered content": { |
| 37 |
"wt2wt": "\nhiho\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho\n|}", |
| 38 |
"selser [2,4]": "12aq8e6\n\n\n\n1jsmwag", |
| 39 |
"selser [[2],0]": "em1p42\n\nhiho\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho", |
| 40 |
"selser [0,[4,0]]": "{|<!--g1bk35-->\n{{tr}}\n{{1x|\n}}\n\nhiho\n|}", |
| 41 |
"selser [2,[3,0]]": "1uq4e67\n\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho\n|}", |
| 42 |
"selser [2,[2,0]]": "tq9px4\n\n{|<!--ityqtj-->\n{{tr}}\n{{1x|\n}}\n\nhiho\n|}", |
| 43 |
"selser [4,0]": "xgjdon\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho", |
| 44 |
"selser [2,2]": "tcvl39\n\n\n\ndky0ja\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho", |
| 45 |
"selser [2,0]": "1fb5hmu\n\n{|\n{{tr}}\n{{1x|\n}}\n\nhiho", |
| 46 |
"selser [3,0]": "{|\n{{tr}}\n{{1x|\n}}\n\nhiho", |
| 47 |
"selser [2,1]": "taa2fs\n\n{| data-foobar=\"l73o9o\"\n{{tr}}\n{{1x|\n}}\n\nhiho\n|}" |
| 48 |
}, |
| 49 |
"1. includeonly in html attr key": { |
| 50 |
"html2wt": "<span id=\"foo\">bar</span>\n" |
| 51 |
}, |
| 52 |
"2. Ensure fostered text content is wrapped in element nodes (traps regressions around fostered marker on the element getting lost)": { |
| 53 |
"wt2wt": "<nowiki>||</nowiki> <nowiki>||</nowiki>\n<table>\n<tr><td> a\n</table>", |
| 54 |
"selser [0,3]": "", |
| 55 |
"selser [1,2]": "<nowiki>||</nowiki> <nowiki>||</nowiki>\n\n1b9dhj9<table>\n<tr> || ||\n<td> a\n</table>", |
| 56 |
"selser [3,2]": "8ukujn<table>\n<tr> || ||\n<td> a\n</table>", |
| 57 |
"selser [0,4]": "\n\n17arlwg", |
| 58 |
"selser [0,2]": "\n\ncib4me<table>\n<tr> || ||\n<td> a\n</table>", |
| 59 |
"selser [2,3]": "16r8fmz\n\n", |
| 60 |
"selser [[4],2]": "1vjq62d\n\n1thr1dd<table>\n<tr> || ||\n<td> a\n</table>", |
| 61 |
"selser [[4],[3,2]]": "o7q8qc<table><!--meualm--><tr> || ||\n<td> a\n</table>", |
| 62 |
"selser [2,[0,2]]": "qokki6\n\n<table>\n<!--660syz--><tr> || ||\n<td> a\n</table>", |
| 63 |
"selser [[3],[3,1]]": "<table><tr> || ||\n<td> a\n</table>", |
| 64 |
"selser [0,[3,0]]": "<table><tr> || ||\n<td> a\n</table>", |
| 65 |
"selser [[4],1]": "xui722<table data-foobar=\"10ikk0v\">\n<tr> || ||\n<td> a\n</table>", |
| 66 |
"selser [1,[2,0]]": "<nowiki>||</nowiki> <nowiki>||</nowiki>\n<table><!--1ltoszy-->\n<tr> || ||\n<td> a\n</table>", |
| 67 |
"selser [2,[0,[3]]]": "rltcpa\n\n<table>\n</table>", |
| 68 |
"selser [[4],[4,2]]": "695dyy<table><!--a592r9--><!--tunxvk--><tr> || ||\n<td> a\n</table>", |
| 69 |
"selser [[2],[0,[[[2]]]]]": "rsud82 || ||\n<table>\n<tr><td> 1a3cvg2 a\n</table>" |
| 70 |
}, |
| 71 |
"2. List embedded in a formatting tag in a misnested way": { |
| 72 |
"html2html": "<p data-parsoid='{\"dsr\":[0,7,0,0]}'><small data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[0,7,7,0]}'></small></p>\n\n<ul data-parsoid='{\"dsr\":[9,24,0,0]}'><small data-parsoid='{\"stx\":\"html\",\"autoInsertedStart\":true,\"autoInsertedEnd\":true,\"dsr\":[9,12,0,0]}'><li data-parsoid='{\"dsr\":[9,12,1,0,1,0]}'>a</li></small>\n<li data-parsoid='{\"dsr\":[13,24,1,0]}'><small data-parsoid='{\"stx\":\"html\",\"autoInsertedStart\":true,\"dsr\":[14,24,0,8]}'> b</small></li></ul>", |
| 73 |
"html2wt": "<small>\n\n* a\n* b</small>" |
| 74 |
}, |
| 75 |
"2. Lists with start-of-line-transparent tokens before bullets: Template close": { |
| 76 |
"wt2html": "<ul about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"dsr\":[0,16,0,0],\"firstWikitextNode\":\"UL\",\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[\"*foo \",{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"bar\\n\"}},\"i\":0}}]}'><li>foo bar</li></ul><span about=\"#mwt1\">\n</span><p data-parsoid='{\"dsr\":[16,20,0,0]}'>*baz</p>", |
| 77 |
"html2html": "<ul about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"dsr\":[0,16,0,0],\"firstWikitextNode\":\"UL\",\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[\"*foo \",{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"bar\\n\"}},\"i\":0}}]}'><li>foo bar</li></ul><span about=\"#mwt1\">\n</span>", |
| 78 |
"html2wt": "*foo {{1x|bar\n}}", |
| 79 |
"selser [0,0,2]": "*foo {{1x|bar\n}}ge6ryx\n\n*baz" |
| 80 |
}, |
| 81 |
"2. Nested mixed wikitext and html list (incompatible)": { |
| 82 |
"html2wt": "; hi\n: {{1x|<li>ho</li>}}" |
| 83 |
}, |
| 84 |
"2. Template wrapping shouldn't ignore fostered content": { |
| 85 |
"wt2wt": "\nhiho\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho\n|}", |
| 86 |
"selser [2,[3,0]]": "7r98ao\n\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho\n|}", |
| 87 |
"selser [[3],0]": "{|\n{{tr}}\n{{1x|\n }}\n\nhiho", |
| 88 |
"selser [0,2]": "\n\nzdnz78\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho", |
| 89 |
"selser [[2],2]": "mkczsa\n\nhiho\n\ntuwhmn\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho", |
| 90 |
"selser [[4],0]": "1vsoxut\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho", |
| 91 |
"selser [0,[4,0]]": "{|<!--iqf0bj-->\n{{tr}}\n{{1x|\n }}\n\nhiho\n|}", |
| 92 |
"selser [2,1]": "1xqx39b\n\n{| data-foobar=\"vh6l68\"\n{{tr}}\n{{1x|\n }}\n\nhiho\n|}", |
| 93 |
"selser [0,1]": "{| data-foobar=\"a0zlmn\"\n{{tr}}\n{{1x|\n }}\n\nhiho\n|}", |
| 94 |
"selser [2,0]": "1j06got\n\n{|\n{{tr}}\n{{1x|\n }}\n\nhiho" |
| 95 |
}, |
| 96 |
"2. includeonly in html attr value": { |
| 97 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,155,0,0]}'><span id=\"v1\" about=\"#mwt1\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"a\":{\"id\":\"v1\"},\"sa\":{\"id\":\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\"},\"dsr\":[0,76,66,7]}' data-mw='{\"attribs\":[[{\"txt\":\"id\"},{\"html\":\"<meta typeof=\\\"mw:Includes/NoInclude\\\" data-parsoid='{\\\"src\\\":\\\"&lt;noinclude>\\\",\\\"dsr\\\":[10,21,null,null]}'/>v1<meta typeof=\\\"mw:Includes/NoInclude/End\\\" data-parsoid='{\\\"src\\\":\\\"&lt;/noinclude>\\\",\\\"dsr\\\":[23,35,null,null]}'/><meta typeof=\\\"mw:Includes/IncludeOnly\\\" data-parsoid='{\\\"dsr\\\":[35,64,null,null]}' data-mw='{\\\"src\\\":\\\"&lt;includeonly>v2&lt;/includeonly>\\\"}'/><meta typeof=\\\"mw:Includes/IncludeOnly/End\\\" data-parsoid='{\\\"src\\\":\\\"\\\",\\\"dsr\\\":[64,64,null,null]}'/>\"}]]}'>bar</span>\n<span id='\"v1\"' about=\"#mwt2\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"a\":{\"id\":\"\\\"v1\\\"\"},\"sa\":{\"id\":\"<noinclude>\\\"v1\\\"</noinclude><includeonly>\\\"v2\\\"</includeonly>\"},\"dsr\":[77,155,68,7]}' data-mw='{\"attribs\":[[{\"txt\":\"id\"},{\"html\":\"<meta typeof=\\\"mw:Includes/NoInclude\\\" data-parsoid='{\\\"src\\\":\\\"&lt;noinclude>\\\",\\\"dsr\\\":[86,97,null,null]}'/>\\\"v1\\\"<meta typeof=\\\"mw:Includes/NoInclude/End\\\" data-parsoid='{\\\"src\\\":\\\"&lt;/noinclude>\\\",\\\"dsr\\\":[101,113,null,null]}'/><meta typeof=\\\"mw:Includes/IncludeOnly\\\" data-parsoid='{\\\"dsr\\\":[113,144,null,null]}' data-mw='{\\\"src\\\":\\\"&lt;includeonly>\\\\\\\"v2\\\\\\\"&lt;/includeonly>\\\"}'/><meta typeof=\\\"mw:Includes/IncludeOnly/End\\\" data-parsoid='{\\\"src\\\":\\\"\\\",\\\"dsr\\\":[144,144,null,null]}'/>\"}]]}'>bar</span></p>", |
| 98 |
"wt2wt": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>\n<span id=\"<noinclude>"v1"</noinclude><includeonly>"v2"</includeonly>\">bar</span>", |
| 99 |
"html2wt": "<span id=\"v1\">bar</span>\n<span id=\"v1\">bar</span>\n", |
| 100 |
"selser [[[4],0,2]]": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">1j63266</span>\n1u6q5h5<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 101 |
"selser [[0,3,[2]]]": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span><span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>vznaa7bar</span>", |
| 102 |
"selser [[4,2,[4]]]": "cjvpt61oh3xt0\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>1yud70z</span>", |
| 103 |
"selser [[1,0,[2]]]": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\" data-foobar=\"1oa66c2\">bar</span>\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>1hzfqd3bar</span>", |
| 104 |
"selser [[[4],4,0]]": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">40cz3h</span>o3mbh9<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 105 |
"selser [[2,0,0]]": "j3euzy<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 106 |
"selser [[2,0,[2]]]": "16p1syu<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>34ckg5bar</span>", |
| 107 |
"selser [2]": "17o3hyu\n\n<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 108 |
"selser [[4,2,0]]": "fi8bu6143igeh\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 109 |
"selser [[2,2,2]]": "19tx1ap<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>yzwmlm\nk9fwvx<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 110 |
"selser [[4,2,[2]]]": "lvcfxg1k1zibr\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>116v95xbar</span>", |
| 111 |
"selser [1]": "<span id=\"<noinclude>v1</noinclude><includeonly>v2</includeonly>\">bar</span>\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>", |
| 112 |
"selser [[3,0,0]]": "\n<span id=<noinclude>\"v1\"</noinclude><includeonly>\"v2\"</includeonly>>bar</span>" |
| 113 |
}, |
| 114 |
"3. cats/langlinks and newlines: newline suppression for last list item should RT properly": { |
| 115 |
"html2wt": "* a\n* b\n \n[[Category:Foo]]\n \n[[Category:Bar]]\n[[Category:Baz]]\n[[es:Foo]]\n\n: c\n\n[[Category:C]]\n\n; d\n\n[[Category:D]]\n[[es:Bar]]", |
| 116 |
"selser [[0,4,0],2,0,0,3,0,0,0,0,0,[[2]],0,4,3,[4],4,3,0,1]": "*a\n* 1je9nn9\n*b\n2wgu5e\n \n[[Category:Foo]]\n \n\n[[Category:Baz]]\n[[es:Foo]]\n\n:oiyhghc\n\n1e9e86j\n: p1o0v3\nhp6fs2\n[[es:Bar]]", |
| 117 |
"selser [4,4,1,0,3,0,0,2,1,2,0,2,2,2,[4],2,3,2,4]": "erm3cp\n\nryijrf\n[[Category:Foo]]\n \n\n[[Category:Baz]]\n13b7wjk\n[[es:Foo]]\nmib3by\n\n:c\n1kra6df\n\n1gd9tyl\n[[Category:C]]\n1wy86xi\n\n: r63zv\n4qio61\n\nnqz955\n\n12y9su", |
| 118 |
"selser [[1,2,3],0,1,2,2,0,0,0,0,4,[2],3,0,4,4,3,0,0,0]": "*a\n* gjpecg\n \n[[Category:Foo]]\n17wx6lj\n \n1bxd8m1\n[[Category:Bar]]\n[[Category:Baz]]\n[[es:Foo]]\nqptth8\n: 55rj2w\n:c\n\n[[Category:C]]\nuhx0e0\n\n1jqrhj9\n[[Category:D]]\n[[es:Bar]]", |
| 119 |
"selser [[0,3,3],0,0,0,4,0,0,0,3,0,3,0,0,3,[2],3,0,3,0]": "*a\n \n[[Category:Foo]]\n \n508fps\n[[Category:Baz]]\n\n\n\n\n[[Category:C]]\n: 15gqjn9\n;d\n[[Category:D]]\n[[es:Bar]]", |
| 120 |
"selser [2,0,2,2,3,0,0,0,4,4,[1],4,0,2,[3],4,2,3,0]": "1erpgb0\n*a\n*b\n \n1gm05hz\n[[Category:Foo]]\nqs2o2x\n \n\n[[Category:Baz]]\n1jrjxjo\n\n1ovl2vk\n:c\n1iivo6q\n[[Category:C]]\nbaqdys\n\n\n15zbdri\n\n1slr19a\n[[Category:D]]\n[[es:Bar]]" |
| 121 |
}, |
| 122 |
"3. includeonly in part of an attr value": { |
| 123 |
"html2wt": "<span style=\"color:red;\">bar</span>\n" |
| 124 |
}, |
| 125 |
"3a. Table cells without escapable prefixes after edits": { |
| 126 |
"selser [manual]": "{|\n| id=\"x\" | -\n|}" |
| 127 |
}, |
| 128 |
"4. cats/langlinks: newline suppression for last list item should RT properly": { |
| 129 |
"html2wt": "* a\n**** b\n\n[[Category:Foo]]\n[[es:Foo]]" |
| 130 |
}, |
| 131 |
"4. includeonly in table attributes": { |
| 132 |
"wt2html": "<table data-parsoid='{\"dsr\":[0,77,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[3,75,0,0]}'><tr about=\"#mwt1\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"startTagSrc\":\"|-\",\"a\":{\"<noinclude>\\n|-\\n|a\\n</noinclude>\":null},\"sa\":{\"<noinclude>\\n|-\\n|a\\n</noinclude>\":\"\"},\"dsr\":[3,36,33,0]}' data-mw='{\"attribs\":[[{\"txt\":\"a\",\"html\":\"<meta typeof=\\\"mw:Includes/NoInclude\\\" data-parsoid='{\\\"src\\\":\\\"&lt;noinclude>\\\",\\\"dsr\\\":[6,17,null,null]}'/>\\n|-\\n|a\\n<meta typeof=\\\"mw:Includes/NoInclude/End\\\" data-parsoid='{\\\"src\\\":\\\"&lt;/noinclude>\\\",\\\"dsr\\\":[24,36,null,null]}'/>\"},{\"html\":\"\"}]]}'></tr>\n<tr about=\"#mwt2\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"startTagSrc\":\"|-\",\"a\":{\"<includeonly>\\n|-\\n|b\\n</includeonly>\":null},\"sa\":{\"<includeonly>\\n|-\\n|b\\n</includeonly>\":\"\"},\"dsr\":[37,74,37,0]}' data-mw='{\"attribs\":[[{\"txt\":\"\",\"html\":\"<meta typeof=\\\"mw:Includes/IncludeOnly\\\" data-parsoid='{\\\"dsr\\\":[40,74,null,null]}' data-mw='{\\\"src\\\":\\\"&lt;includeonly>\\\\n|-\\\\n|b\\\\n&lt;/includeonly>\\\"}'/><meta typeof=\\\"mw:Includes/IncludeOnly/End\\\" data-parsoid='{\\\"src\\\":\\\"\\\",\\\"dsr\\\":[74,74,null,null]}'/>\"},{\"html\":\"\"}]]}'></tr>\n</tbody></table>", |
| 133 |
"html2wt": "{|\n|a\n|}" |
| 134 |
}, |
| 135 |
"7. cats/langlinks: migrateTrailingSolTransparentLinks dom pass should leave template content alone": { |
| 136 |
"html2wt": "* {{1x|a\n[[Category:Foo]]\n[[es:Foo]]}}" |
| 137 |
}, |
| 138 |
"8. Encapsulate foster-parented transclusion content": { |
| 139 |
"wt2wt": "{{1x|a\n}}\n{|{{1x|style='color:red'}}\n|-\n|b\n|}\n" |
| 140 |
}, |
| 141 |
"8. cats/langlinks: migrateTrailingSolTransparentLinks dom pass should not get tripped by intervening templates": { |
| 142 |
"html2wt": "* a\n\n{{1x|[[Category:Foo]]\n[[Category:Bar]]}}\n[[Category:Baz]]\n[[es:Baz]]" |
| 143 |
}, |
| 144 |
"<br> to <br />": { |
| 145 |
"html2html": "<p data-parsoid='{\"dsr\":[0,3,0,0]}'>123</p>\n", |
| 146 |
"html2wt": "123\n" |
| 147 |
}, |
| 148 |
"<includeonly> and <noinclude> being included": { |
| 149 |
"html2wt": "Foobar\n" |
| 150 |
}, |
| 151 |
"<onlyinclude> on a page": { |
| 152 |
"html2wt": "Foobar\n" |
| 153 |
}, |
| 154 |
"<pre> inside a link": { |
| 155 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,6,0,0]}'>[[Main</p><pre typeof=\"mw:Extension/pre\" about=\"#mwt10\" data-parsoid='{\"stx\":\"html\",\"dsr\":[6,22,5,6]}' data-mw='{\"name\":\"pre\",\"attrs\":{},\"body\":{\"extsrc\":\" Page\"}}'> Page</pre><p data-parsoid='{\"dsr\":[22,84,0,0]}'>]] <a rel=\"mw:WikiLink\" href=\"./Main_Page\" title=\"Main Page\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./Main_Page\"},\"sa\":{\"href\":\"Main Page\"},\"dsr\":[25,84,12,2]}'>the main page <pre typeof=\"mw:Extension/pre\" about=\"#mwt5\" data-parsoid='{\"stx\":\"html\",\"dsr\":[51,82,5,6]}' data-mw='{\"name\":\"pre\",\"attrs\":{},\"body\":{\"extsrc\":\"[it's not very good]\"}}'>[it's not very good]</pre></a></p>", |
| 156 |
"wt2wt": "[[Main<pre> Page</pre>]] [[Main Page|the main page]]<pre>[it's not very good]</pre>", |
| 157 |
"html2html": "<p data-parsoid='{\"dsr\":[0,6,0,0]}'>[[Main</p><pre typeof=\"mw:Extension/pre\" about=\"#mwt11\" data-parsoid='{\"stx\":\"html\",\"dsr\":[6,22,5,6]}' data-mw='{\"name\":\"pre\",\"attrs\":{},\"body\":{\"extsrc\":\" Page\"}}'> Page</pre><p data-parsoid='{\"dsr\":[22,52,0,0]}'>]] <a rel=\"mw:WikiLink\" href=\"./Main_Page\" title=\"Main Page\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./Main_Page\"},\"sa\":{\"href\":\"Main Page\"},\"dsr\":[25,52,12,2]}'>the main page</a></p><pre typeof=\"mw:Extension/pre\" about=\"#mwt4\" data-parsoid='{\"stx\":\"html\",\"dsr\":[52,83,5,6]}' data-mw='{\"name\":\"pre\",\"attrs\":{},\"body\":{\"extsrc\":\"[it's not very good]\"}}'>[it's not very good]</pre>", |
| 158 |
"html2wt": "[[Main<pre> Page</pre>]] [[Main Page|the main page]]<pre>[it's not very good]</pre>", |
| 159 |
"selser [5]": "[[Main<pre> Page</pre>]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 160 |
"selser [[3],0,2,0,0]": "<pre> Page</pre>1aryxb3\n\n]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 161 |
"selser [3,0,2,0,4]": "<pre> Page</pre>1lj0yiu\n\n]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>745xgq", |
| 162 |
"selser [3,0,1,0,0]": "<pre> Page</pre>]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 163 |
"selser [0,0,[4,2],0,2]": "[[Main<pre> Page</pre>11x2vdb14osc5u[[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>1k4l5na\n\n", |
| 164 |
"selser [3,0,1,0,1]": "<pre> Page</pre>]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 165 |
"selser [2,0,[4,0],0,2]": "hhy6o3\n\n[[Main<pre> Page</pre>1ykqzio[[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>ia94fo\n\n", |
| 166 |
"selser [4,0,1,0,1]": "1j63aso<pre> Page</pre>]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 167 |
"selser [[3],0,[0,2],0,4]": "<pre> Page</pre>]] 1ecrp36[[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>1ewp809", |
| 168 |
"selser [4,0,2,0,0]": "c95k3k<pre> Page</pre>m0cfjh\n\n]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>", |
| 169 |
"selser [2,0,0,0,3]": "1cto0y\n\n[[Main<pre> Page</pre>]] [[Main Page|the main page <pre>[it's not very good]</pre>]]<pre>[it's not very good]</pre>" |
| 170 |
}, |
| 171 |
"<wbr> is valid wikitext (T54468)": { |
| 172 |
"html2wt": "<wbr />\n" |
| 173 |
}, |
| 174 |
"Accept empty attributes in th-cells": { |
| 175 |
"html2wt": "{|\n!foo\n!bar\n|}" |
| 176 |
}, |
| 177 |
"Accept empty td cell attribute": { |
| 178 |
"html2wt": "{|\n| align=\"center\" |foo\n|\n|}" |
| 179 |
}, |
| 180 |
"Anchor containing a #. (T65430)": { |
| 181 |
"metadata": "" |
| 182 |
}, |
| 183 |
"Attribute test: unquoted but illegal value (hash)": { |
| 184 |
"wt2wt": "<font color=\"#x\">foo</font>", |
| 185 |
"html2wt": "<font color=\"#x\">foo</font>\n", |
| 186 |
"selser [[2]]": "4p94qb<font color=#x>foo</font>", |
| 187 |
"selser [1]": "<font color=#x>foo</font>", |
| 188 |
"selser [2]": "1t5s407\n\n<font color=#x>foo</font>", |
| 189 |
"selser [[[2]]]": "<font color=#x>1hva2gnfoo</font>", |
| 190 |
"selser [[[3]]]": "<font color=#x></font>", |
| 191 |
"selser [[[4]]]": "<font color=#x>1wi04hg</font>" |
| 192 |
}, |
| 193 |
"Bail on table cell attribute parsing on wikilink": { |
| 194 |
"wt2wt": "{|\n|testing [[one|two]]<nowiki> |three</nowiki>||four\n| testing one two |three||four\n|testing=\"[[one|two]]<nowiki>\" |three</nowiki>||four\n|}", |
| 195 |
"html2html": "<table data-parsoid='{\"dsr\":[0,140,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[3,138,0,0]}'><tr data-parsoid='{\"autoInsertedStart\":true,\"dsr\":[3,137,0,0]}'><td data-parsoid='{\"dsr\":[3,47,1,0]}'>testing <a rel=\"mw:WikiLink\" href=\"./One\" title=\"One\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./One\"},\"sa\":{\"href\":\"one\"},\"dsr\":[12,23,6,2]}'>two</a><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[23,47,8,9]}'> |three</span></td><td data-parsoid='{\"stx\":\"row\",\"dsr\":[47,53,2,0]}'>four</td>\n<td data-parsoid='{\"a\":{\"testing\":null,\"one\":null,\"two\":null},\"sa\":{\"testing\":\"\",\"one\":\"\",\"two\":\"\"},\"dsr\":[54,78,19,0]}'>three</td><td data-parsoid='{\"stx\":\"row\",\"dsr\":[78,84,2,0]}'>four</td>\n<td data-parsoid='{\"dsr\":[85,131,1,0]}'>testing=\"<a rel=\"mw:WikiLink\" href=\"./One\" title=\"One\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./One\"},\"sa\":{\"href\":\"one\"},\"dsr\":[95,106,6,2]}'>two</a><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[106,131,8,9]}'>\" |three</span></td><td data-parsoid='{\"stx\":\"row\",\"dsr\":[131,137,2,0]}'>four</td></tr>\n</tbody></table>", |
| 196 |
"html2wt": "{|\n|testing [[one|two]]<nowiki> |three</nowiki>||four\n| testing one two |three||four\n|testing=\"[[one|two]]<nowiki>\" |three</nowiki>||four\n|}", |
| 197 |
"selser [[3,1]]": "{|\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 198 |
"selser [[3,[2,0]]]": "{|<!--xb8p09-->\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 199 |
"selser [2]": "hgisit\n{|\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 200 |
"selser [[0,2]]": "{|\n<!--s1ac4r-->|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 201 |
"selser [1]": "{| data-foobar=\"m6t5pu\"\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 202 |
"selser [[4,[[1,[4],2,[3],[4],3,[2,1,0],0],3]]]": "{|<!--15jn3oo-->\n| data-foobar=\"1dpsv1f\" |testing [[one|two]] |three||shmm44\n|1a9hxti\n| testing one two | ||u4sv1d\n|7kwa0etesting=\"[[one|two]]<nowiki>\" |three</nowiki>||four\n|}", |
| 203 |
"selser [[3,2]]": "{|<!--1bcn9tp-->\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 204 |
"selser [[4,[[0,2,0,4,3,0,[2,0,3],4],2]]]": "{|<!--ucy21x-->\n|testing [[one|two]] |three\n|1sw2rre||four\n|lmqy2j\n|203rzetesting=\"[[one|two]]\n|1boms42<!--cy3v8j-->\n|}", |
| 205 |
"selser [[0,[2,2]]]": "{|\n<!--1a5ha30-->|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four<!--1xb2qs8-->\n|}", |
| 206 |
"selser [[0,1]]": "{|\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 207 |
"selser [[2,2]]": "{|<!--1ya6ph8-->\n<!--wmgbkt-->|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 208 |
"selser [[0,[1,0]]]": "{|\n|testing [[one|two]] |three||four\n|testing one two |three||four\n|testing=\"[[one|two]]\" |three||four\n|}", |
| 209 |
"selser [[0,[[2,0,0,[3],3,0,3,0],4]]]": "{|\n|6oy5gu\n|testing [[one|two]] |three||four\n|testing one two | \n|four<!--1xkfpb6-->\n|}" |
| 210 |
}, |
| 211 |
"Bare pipe character from a template (T54363)": { |
| 212 |
"html2wt": "|\n" |
| 213 |
}, |
| 214 |
"Broken link with fragment": { |
| 215 |
"metadata": "" |
| 216 |
}, |
| 217 |
"CSS line continuation 1": { |
| 218 |
"html2wt": "<div style=\"/* insecure input */\"></div>" |
| 219 |
}, |
| 220 |
"CSS line continuation 2": { |
| 221 |
"html2wt": "<div style=\"/* invalid control char */\"></div>" |
| 222 |
}, |
| 223 |
"Case insensitivity of parser functions for non-ASCII characters (T10143)": { |
| 224 |
"html2wt": "Ěščř\nĚščř\něščř\něščř\něščř\něščř\nĚŠČŘ\nĚŠČŘ\n" |
| 225 |
}, |
| 226 |
"Categories and newlines: should behave properly with linkprefix (T87753)": { |
| 227 |
"selser [[3],0,3,0,0]": "\n\n[[تصنيف:Bar]]" |
| 228 |
}, |
| 229 |
"Category with newline in sort key": { |
| 230 |
"metadata": "cat=Wikidata:Tools sort=*" |
| 231 |
}, |
| 232 |
"Common list": { |
| 233 |
"html2wt": "* Common list\n* item 2\n* item 3" |
| 234 |
}, |
| 235 |
"Confirm that 'apos' named character reference doesn't make it to output (not legal in HTML 4)": { |
| 236 |
"html2wt": "Text's been normalized?\n" |
| 237 |
}, |
| 238 |
"Consecutive <pre>s should not get merged": { |
| 239 |
"html2html": "<pre data-parsoid='{\"dsr\":[0,2,1,0]}'>a</pre>\n\n<pre data-parsoid='{\"dsr\":[4,6,1,0]}'>b</pre>\n\n<pre data-parsoid='{\"dsr\":[8,10,1,0]}'>c</pre>\n\n<pre data-parsoid='{\"dsr\":[12,14,1,0]}'>d</pre>\n\n<pre data-parsoid='{\"dsr\":[16,18,1,0]}'>e</pre>\n <p data-parsoid='{\"dsr\":[20,21,0,0]}'>\n<br data-parsoid='{\"dsr\":[21,21,0,0]}'/></p>\n \n<pre data-parsoid='{\"dsr\":[24,26,1,0]}'>f</pre>\n" |
| 240 |
}, |
| 241 |
"Correct handling of <td>, <tr> (T8171)": { |
| 242 |
"html2wt": "{| \n | Some tabular data\n | More tabular data ...\n | And yet som tabular data \n|}", |
| 243 |
"selser [[0,[[0,0,0,[4],4,0,3],0]]]": "<table>\n <tr>\n <td> Some tabular data</td>\n <td> pa70ih</td><td>ewy9pe</td><td> And yet som tabular data</td></tr>\n</table>", |
| 244 |
"selser [[4,[[4,1,0,[2],0,[4],3],2]]]": "<table><!--1c9p8ag--><tr><td>8f9cr6</td><td data-foobar=\"trdzwz\"> Some tabular data</td>\n <td> 10bfmus More tabular data ...</td>\n <td> brkgdj</td></tr><!--1s1b0su-->\n</table>", |
| 245 |
"selser [[2,[[3,[2],4,[3],3,[4],0],3]]]": "<table><!--kic9hg-->\n <tr><td> 5jp55q Some tabular data</td><td>zxz05u</td><td></td><td> 1l2mrts</td>\n </tr>\n</table>" |
| 246 |
}, |
| 247 |
"DIV IN UPPERCASE": { |
| 248 |
"wt2wt": "<DIV id=\"x\">HTML ROCKS</DIV>", |
| 249 |
"html2wt": "<div id=\"x\">HTML ROCKS</div>", |
| 250 |
"selser [2]": "pdj6w1<DIV ID=\"x\">HTML ROCKS</DIV>", |
| 251 |
"selser [[2]]": "<DIV ID=\"x\">tde5ezHTML ROCKS</DIV>", |
| 252 |
"selser [[4]]": "<DIV ID=\"x\">1ntl0vu</DIV>", |
| 253 |
"selser [[3]]": "<DIV ID=\"x\"></DIV>" |
| 254 |
}, |
| 255 |
"Dir parser function (invalid code)": { |
| 256 |
"metadata": "" |
| 257 |
}, |
| 258 |
"Don't fall for the self-closing div": { |
| 259 |
"wt2wt": "<div>hello world</div>", |
| 260 |
"html2wt": "<div>hello world</div>", |
| 261 |
"selser [[4]]": "<div>3bqvzz</div/>", |
| 262 |
"selser [[3]]": "<div></div/>", |
| 263 |
"selser [2]": "12umu83<div>hello world</div/>", |
| 264 |
"selser [[2]]": "<div>1c5s34thello world</div/>" |
| 265 |
}, |
| 266 |
"Empty LI (T49673)": { |
| 267 |
"wt2wt": "*a\n*\n*\n*b", |
| 268 |
"html2wt": "* a\n*\n*\n* b", |
| 269 |
"selser [1]": "*a\n* \n*\n*b", |
| 270 |
"selser [[0,4,2,0,0,4,3]]": "*a\n* 1e4qfs2\n* 4mb816\n* \n*\n* 8x7hb9", |
| 271 |
"selser [[2,0,0,3,0,2,[2]]]": "* 65v4jt\n*a\n* \n*\n* faupxr\n*ky9hbbb", |
| 272 |
"selser [[0,2,0,0,1,2,[2]]]": "*a\n* 1k486vt\n* \n*\n* 1xmr7e0\n*16s6j1gb", |
| 273 |
"selser [2]": "1ei47dn\n*a\n* \n*\n*b", |
| 274 |
"selser [[3,0,0,4,0,0,0]]": "* \n* 41ayue\n*\n*b", |
| 275 |
"selser [[0,2,2,2,0,4,0]]": "*a\n* mfrkd9\n* 13dow6x\n* \n* w2eup1\n*\n* petpa8\n*b", |
| 276 |
"selser [[0,2,0,2,0,2,1]]": "*a\n* ip7ko3\n* \n* 4yowy5\n*\n* 310ii7\n*b", |
| 277 |
"selser [[0,2,0,0,4,0,0]]": "*a\n* 1xdkv8p\n* \n* b38u28\n*b", |
| 278 |
"selser [[3,2,0,0,0,4,2]]": "* 1e64d2u\n* \n*\n* 16l2rkw\n* 1azuhc\n*b", |
| 279 |
"selser [[[3],0,0,0,0,4,2]]": "*\n* \n*\n* 15pcaxr\n* 1sf1nsf\n*b", |
| 280 |
"selser [[0,4,2,4,0,4,[4]]]": "*a\n* f55lvy\n* x7e1m9\n* \n* s7jsjj\n*\n* 13f4m7h\n*9tz76v" |
| 281 |
}, |
| 282 |
"Empty LI and TR nodes should not be stripped from top-level content": { |
| 283 |
"html2html": "<ul data-parsoid='{\"dsr\":[0,9,0,0]}'><li data-parsoid='{\"dsr\":[0,3,1,0,1,0]}'>a</li>\n<li class=\"mw-empty-elt\" data-parsoid='{\"dsr\":[4,5,1,0]}'></li>\n<li data-parsoid='{\"dsr\":[6,9,1,0,1,0]}'>b</li></ul>\n\n<table data-parsoid='{\"dsr\":[11,24,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[14,22,0,0]}'><tr data-parsoid='{\"startTagSrc\":\"|-\",\"dsr\":[14,21,2,0]}'>\n<td data-parsoid='{\"dsr\":[17,21,1,0]}'>foo</td></tr>\n</tbody></table>", |
| 284 |
"html2wt": "* a\n*\n* b\n\n{|\n|-\n|foo\n|}" |
| 285 |
}, |
| 286 |
"Empty TD followed by TD with tpl-generated attribute": { |
| 287 |
"wt2wt": "{|\n|-\n|\n| {{1x|style='color:red'}} |foo\n|}", |
| 288 |
"html2wt": "{|\n|\n|foo\n|}", |
| 289 |
"selser [1]": "{| data-foobar=\"h5cb1o\"\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 290 |
"selser [2]": "204y7q\n{|\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 291 |
"selser [[0,[[2,0,0,0],0]]]": "{|\n|-\n|hssbe0\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 292 |
"selser [[0,[1,4]]]": "{|\n|- data-foobar=\"16febr0\"\n|\n|{{1x|style='color:red'}}|foo<!--1fw320c-->\n|}", |
| 293 |
"selser [[0,2]]": "{|\n<!--17w8mfe-->|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 294 |
"selser [[4,2]]": "{|<!--1r5l00v--><!--n467mo-->\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 295 |
"selser [[4,[2,0]]]": "{|<!--m5h5v1--><!--1kdmhei-->\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 296 |
"selser [[0,1]]": "{|\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}", |
| 297 |
"selser [[3,[[0,2,0,0],2]]]": "{|\n|-\n|bqbnlp\n|\n|{{1x|style='color:red'}}|foo<!--1rteuuo-->\n|}", |
| 298 |
"selser [[4,1]]": "{|<!--95fu82-->\n|-\n|\n|{{1x|style='color:red'}}|foo\n|}" |
| 299 |
}, |
| 300 |
"Empty TR followed by a template-generated TR": { |
| 301 |
"html2html": "<table data-parsoid='{\"dsr\":[0,34,2,2]}'>\n<tbody about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[3,31,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"<tr><td>foo</td></tr>\"}},\"i\":0}}]}'><tr><td>foo</td></tr></tbody>\n</table>", |
| 302 |
"html2wt": "{|\n{{1x|<tr><td>foo</td></tr>}}\n|}" |
| 303 |
}, |
| 304 |
"Empty TR followed by mixed-ws-comment line should RT correctly": { |
| 305 |
"html2html": "<table data-parsoid='{\"dsr\":[0,36,2,2]}'>\n <!--c-->\n<tbody data-parsoid='{\"dsr\":[13,34,0,0]}'><tr class=\"mw-empty-elt\" data-parsoid='{\"startTagSrc\":\"|-\",\"dsr\":[13,25,2,0]}'>\n<!--c--> </tr><!--d-->\n</tbody></table>", |
| 306 |
"html2wt": "{|\n <!--c-->\n|-\n<!--c--> <!--d-->\n|}" |
| 307 |
}, |
| 308 |
"Empty attribute crash test single-quotes (T4067)": { |
| 309 |
"wt2wt": "<font color=\"\">foo</font>", |
| 310 |
"html2wt": "<font color=\"\">foo</font>\n", |
| 311 |
"selser [1]": "<font color=''>foo</font>", |
| 312 |
"selser [2]": "8qlka6\n\n<font color=''>foo</font>", |
| 313 |
"selser [[[4]]]": "<font color=''>xdaycm</font>", |
| 314 |
"selser [[2]]": "knc6p1<font color=''>foo</font>", |
| 315 |
"selser [[[3]]]": "<font color=''></font>", |
| 316 |
"selser [[[2]]]": "<font color=''>1ug2z4vfoo</font>" |
| 317 |
}, |
| 318 |
"Empty table rows go away": { |
| 319 |
"wt2html": "<table data-parsoid='{\"dsr\":[0,37,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[3,35,0,0]}'><tr data-parsoid='{\"autoInsertedStart\":true,\"dsr\":[3,16,0,0]}'><td data-parsoid='{\"dsr\":[3,9,1,0]}'>Hello</td>\n<td data-parsoid='{\"dsr\":[10,16,1,0]}'>there</td></tr>\n<tr class=\"foo\" data-parsoid='{\"startTagSrc\":\"|-\",\"dsr\":[17,31,14,0]}'></tr>\n<tr class=\"mw-empty-elt\" data-parsoid='{\"startTagSrc\":\"|-\",\"dsr\":[32,34,2,0]}'></tr>\n</tbody></table>", |
| 320 |
"html2wt": "{|\n|Hello\n|there\n|}" |
| 321 |
}, |
| 322 |
"Expansion of multi-line templates in attribute values (T8255 check 2)": { |
| 323 |
"html2wt": "<div style=\"background: \n#00FF00\">-</div>" |
| 324 |
}, |
| 325 |
"Extra new lines before and after lists are preserved": { |
| 326 |
"html2wt": "a\n\n\n* b\n\n\nc", |
| 327 |
"selser [0,0,[3,0],0,[4],3,3]": "a\n\n\n\n* 10x2a1y", |
| 328 |
"selser [[3],4,[4,0],0,3,3,4]": "\n\n1htrbwe\n\nmbdls4\n\nlhzama", |
| 329 |
"selser [1,0,[0,3],4,0,0,2]": "a\n\n1sdlaev\n*b\n1k8xl54\n\n\n\nc", |
| 330 |
"selser [0,0,[4,1],3,4,4,0]": "a\n\n1484fwk\n\n1skjf24\n\n7z2qry\n\n\n\nc", |
| 331 |
"selser [[3],0,[3,0],0,[4],3,0]": "\n\n\n* x7yop0\n\n\nc", |
| 332 |
"selser [1,0,1,0,3,0,[4,4,0]]": "a\n\n\n\n\n\n1qciwap1xd4cx7\nc", |
| 333 |
"selser [3,0,4,0,0,2,2]": "\n13hqha1\n*b\n8hjyf9\n\n1jhwsov\n\n\n\nc", |
| 334 |
"selser [[3],3,2,3,[4],0,[0,3,2]]": "\n\nvtvy93\n\n\n\n* vpduic\n\n1nly2ch\nc", |
| 335 |
"selser [0,0,2,0,[1],0,[0,0,2]]": "a\n\n19jl0yl\n\n\n\n*b\n\ny4gtyn\nc", |
| 336 |
"selser [[3],0,[3,0],0,3,0,[0,0,4]]": "\n\n\n\n\ny9onar", |
| 337 |
"selser [0,2,0,3,4,0,1]": "a\n\n16q6yvm\n\n\n\n\nu1mp0q\n\n\nc" |
| 338 |
}, |
| 339 |
"Extra newlines: More paragraphs with indented comment": { |
| 340 |
"html2wt": "a\n\n\nb\n", |
| 341 |
"selser [[4],3,[0,0,0,0,3]]": "2tueq6\n\n\n <!--boo-->\n", |
| 342 |
"selser [2,2,0]": "cb3anx\n\na\n\ntiyqt3\n\n\n <!--boo-->\n\nb" |
| 343 |
}, |
| 344 |
"Failing to transform badly formed HTML into correct XHTML": { |
| 345 |
"html2html": "\n<p data-parsoid='{\"autoInsertedEnd\":true,\"dsr\":[1,2,0,0]}'>\n<br data-parsoid='{\"dsr\":[2,2,0,0]}'/></p>\n", |
| 346 |
"html2wt": "\n\n\n" |
| 347 |
}, |
| 348 |
"Fuzz testing: Parser13": { |
| 349 |
"wt2wt": "{| \n| http: / a |\n|}", |
| 350 |
"html2wt": "{|\n|\n|}", |
| 351 |
"selser [2]": "7lvj1j\n{| \n| http://a|", |
| 352 |
"selser [1]": "{| data-foobar=\"142ul44\" \n| http://a|\n|}", |
| 353 |
"selser [[2,2]]": "{|<!--c6mkjc--> \n<!--xu44dy-->| http://a|\n|}", |
| 354 |
"selser [[4,2]]": "{|<!--1a321i4--><!--bi4yli-->\n| http://a|\n|}", |
| 355 |
"selser [[0,1]]": "{| \n| http://a|\n|}", |
| 356 |
"selser [[0,2]]": "{| \n<!--1gsyrc8-->| http://a|\n|}", |
| 357 |
"selser [[0,[1]]]": "{| \n| http://a|\n|}", |
| 358 |
"selser [[4,[1]]]": "{|<!--ll5x1s-->\n| http://a|\n|}", |
| 359 |
"selser [[4,0]]": "{|<!--zr6ccr-->\n| http://a|\n|}", |
| 360 |
"selser [[2,0]]": "{|<!--f1fd4x--> \n| http://a|\n|}" |
| 361 |
}, |
| 362 |
"Fuzz testing: Parser16": { |
| 363 |
"wt2wt": "{|\n!https://|| || ||\n|}", |
| 364 |
"html2wt": "{|\n!https://\n!\n!\n!\n|}", |
| 365 |
"selser [2]": "k5vjya\n{|\n!https://||||||", |
| 366 |
"selser [[0,[[0,2,0,0]]]]": "{|\n!https://\n!1t89i6n|| ||||\n|}", |
| 367 |
"selser [[3,2]]": "{|<!--bn7pt9-->\n!https://||||||\n|}", |
| 368 |
"selser [[0,1]]": "{|\n!https://||||||\n|}", |
| 369 |
"selser [[3,[2]]]": "{|<!--1dlafod-->\n!https://||||||\n|}", |
| 370 |
"selser [[0,[[1,0,0,4]]]]": "{|\n! data-foobar=\"1ok43yp\" |https://||||\n!1fq9xmt\n|}", |
| 371 |
"selser [1]": "{| data-foobar=\"kstqm9\"\n!https://||||||\n|}" |
| 372 |
}, |
| 373 |
"Fuzz testing: Parser21": { |
| 374 |
"wt2wt": "{|\n!irc://{{ftp://a\" onmouseover=\"alert('hello world');\"\n|\n|}", |
| 375 |
"html2wt": "{|\n!irc://{{ftp://a\" onmouseover=\"alert('hello world');\"\n|\n|}", |
| 376 |
"selser [2]": "1myp0d5\n{|\n!irc://{{ftp://a\" onmouseover=\"alert('hello world');\"\n|" |
| 377 |
}, |
| 378 |
"Fuzz testing: Parser22": { |
| 379 |
"wt2wt": "http://===r:::https://b\n\n{|\n|}", |
| 380 |
"html2wt": "http://===r:::https://b\n\n{|\n|}", |
| 381 |
"selser [[4],0,0]": "8xe2up\n\n{|", |
| 382 |
"selser [1,2,2]": "http://===r:::https://b\n\n1yix1da\n\nq9ygvp\n{|", |
| 383 |
"selser [1,3,0]": "http://===r:::https://b\n{|", |
| 384 |
"selser [[1],0,0]": "http://===r:::https://b\n\n{|", |
| 385 |
"selser [[[3]],0,0]": "[http://===r:::https://b]\n\n{|", |
| 386 |
"selser [[2],0,2]": "1dzr7tk<nowiki/>http://===r:::https://b\n\nu2b7xx\n{|", |
| 387 |
"selser [2,0,0]": "19oh6e\n\nhttp://===r:::https://b\n\n{|", |
| 388 |
"selser [3,2,2]": "hjkko9\n\nev6d0n\n{|", |
| 389 |
"selser [[4],0,2]": "34avcu\n\n188pvr7\n{|", |
| 390 |
"selser [[2],0,0]": "1ek53qi<nowiki/>http://===r:::https://b\n\n{|", |
| 391 |
"selser [[1],4,2]": "http://===r:::https://b\n\nxk2i4b\n\nhs5n9j\n{|", |
| 392 |
"selser [3,0,0]": "\n{|", |
| 393 |
"selser [1,0,2]": "http://===r:::https://b\n\ntkvjp1\n{|" |
| 394 |
}, |
| 395 |
"HTML bullet list, closed tags (T7497)": { |
| 396 |
"selser [[4,[3],3,0,3]]": "<ul><li>1a9n41r</li><li></li>\n<li>Two</li></ul>", |
| 397 |
"selser [[4,[2],3,0,0]]": "<ul><li>eoh8fa</li><li>t6txntOne</li>\n<li>Two</li>\n</ul>" |
| 398 |
}, |
| 399 |
"HTML multiple attributes correction": { |
| 400 |
"wt2wt": "<p class=\"awesome\">Awesome!</p>", |
| 401 |
"html2wt": "Awesome!", |
| 402 |
"selser [2]": "17jezgw<p class=\"error\" class=\"awesome\">Awesome!</p>", |
| 403 |
"selser [[3]]": "<p class=\"error\" class=\"awesome\"></p>", |
| 404 |
"selser [[4]]": "<p class=\"error\" class=\"awesome\">1h5lng</p>", |
| 405 |
"selser [[2]]": "<p class=\"error\" class=\"awesome\">deh48tAwesome!</p>" |
| 406 |
}, |
| 407 |
"HTML nested bullet list, open tags (T7497)": { |
| 408 |
"html2wt": "* One\n* Two:\n** Sub-one\n** Sub-two\n" |
| 409 |
}, |
| 410 |
"HTML nested ordered list, closed tags (T7497)": { |
| 411 |
"html2wt": "# One\n# Two:\n## Sub-one\n## Sub-two\n" |
| 412 |
}, |
| 413 |
"HTML nested ordered list, open tags (T7497)": { |
| 414 |
"html2wt": "# One\n# Two:\n## Sub-one\n## Sub-two\n", |
| 415 |
"selser [[2,3,4,[2,1],3]]": "<ol><li>1i8pngl</li>\n<li>dbj7yi</li><li>1w4djewTwo:\n<ol data-foobar=\"up9fas\">\n<li>Sub-one\n<li>Sub-two\n</ol>\n</ol>" |
| 416 |
}, |
| 417 |
"HTML ordered list item with parameters oddity": { |
| 418 |
"html2html": "<ol data-parsoid='{\"dsr\":[0,5,0,0]}'><li data-parsoid='{\"dsr\":[0,5,1,0,1,0]}'>One</li></ol>\n", |
| 419 |
"html2wt": "# One\n" |
| 420 |
}, |
| 421 |
"HTML tag with 'unnecessary' entity encoding in attributes": { |
| 422 |
"html2wt": "<span title=\"&\">foo</span>\n" |
| 423 |
}, |
| 424 |
"Handling html with a br self-closing tag": { |
| 425 |
"wt2wt": "<br title=\"\" />\n<br title=\"\" />\n<br title=\"\">\n<br title=\"bar\" />\n<br title=\"bar\" />\n<br title=\"bar/\">", |
| 426 |
"html2html": "\n<p data-parsoid='{\"autoInsertedEnd\":true,\"dsr\":[1,2,0,0]}'>\n<br data-parsoid='{\"dsr\":[2,2,0,0]}'/></p>\n", |
| 427 |
"html2wt": "\n\n\n", |
| 428 |
"selser [[0,2,2,0,0,3,0,4,0,0,0]]": "<br title />yk0l4q\nnag8u8<br title/>\n<br title/ ><br title=bar />18a7fo<br title=bar/>\n<br title=bar/ >", |
| 429 |
"selser [2]": "1bhw13d\n\n<br title />\n<br title/>\n<br title/ >\n<br title=bar />\n<br title=bar/>\n<br title=bar/ >", |
| 430 |
"selser [1]": "<br title />\n<br title/>\n<br title/ >\n<br title=bar />\n<br title=bar/>\n<br title=bar/ >", |
| 431 |
"selser [[0,2,2,3,0,2,1,0,4,2,2]]": "<br title />6kjv2v\n1ddl3ij<br title/><br title/ >10enb3k\n<br title=\"bar\" data-foobar=\"1afcm8\" />\nqjfnqp3yide2\nplu61x<br title=bar/ >", |
| 432 |
"selser [[0,4,4,4,3,0,4,2,0,2,0]]": "<br title />1pqtyn6gbvfw7do43wi\n1f1qqzg7qp69\n<br title=bar/>8pv0cs\n<br title=bar/ >", |
| 433 |
"selser [[0,0,2,4,0,2,3,2,0,4,0]]": "<br title />\nw4dpzv<br title/>1sqbuv6<br title/ >1v9rszq\nqxpzb\n<br title=bar/>ly1422<br title=bar/ >", |
| 434 |
"selser [[2,0,0,3,0,0,0,4,0,0,0]]": "14z8tu9<br title />\n<br title/><br title/ >\n<br title=bar />1jr6i1s<br title=bar/>\n<br title=bar/ >", |
| 435 |
"selser [[3,0,0,2,4,4,0,0,0,3,2]]": "\n<br title/>rlmvl6\nmrqsaepknvzd<br title=bar />\n<br title=bar/>5fmysy<br title=bar/ >", |
| 436 |
"selser [[0,4,1,4,1,0,0,0,0,3,0]]": "<br title />groqlz<br title=\"\" data-foobar=\"1bcyhwz\" />13ok70i<br title=\"\" data-foobar=\"vr3c2f\">\n<br title=bar />\n<br title=bar/><br title=bar/ >", |
| 437 |
"selser [[2,2,0,2,0,0,0,0,0,0,1]]": "mu3lme<br title />1252nyk\n<br title/>oia9w4\n<br title/ >\n<br title=bar />\n<br title=bar/>\n<br title=\"bar/\" data-foobar=\"qfwlzu\">", |
| 438 |
"selser [[0,0,0,4,2,4,1,0,3,0,0]]": "<br title />\n<br title/>1544u7r1bqhxo<br title/ >1yxsbno<br title=\"bar\" data-foobar=\"axh3jm\" />\n\n<br title=bar/ >", |
| 439 |
"selser [[1,0,4,0,0,4,0,2,0,0,0]]": "<br title=\"\" data-foobar=\"16bphiz\" />\n1gy59en\n<br title/ >16jn5s5<br title=bar />1wgpy1l\n<br title=bar/>\n<br title=bar/ >", |
| 440 |
"selser [[0,0,0,2,1,0,0,2,4,0,0]]": "<br title />\n<br title/>4oshv1\n<br title=\"\" data-foobar=\"i2q3ei\">\n<br title=bar />q1569r\njdxtvf\n<br title=bar/ >", |
| 441 |
"selser [[0,0,0,4,0,0,2,0,3,0,4]]": "<br title />\n<br title/>9gus2q<br title/ >\n1oyrjb6<br title=bar />\n\nor7p00", |
| 442 |
"selser [[0,3,0,2,0,4,0,2,0,3,3]]": "<br title /><br title/>h2az2u\n<br title/ >180h0zi<br title=bar />10wbncx\n<br title=bar/>", |
| 443 |
"selser [[1,3,0,0,4,0,2,0,0,3,0]]": "<br title=\"\" data-foobar=\"aqcwn0\" /><br title/>\n1o8hxpp\n2dslnu<br title=bar />\n<br title=bar/><br title=bar/ >", |
| 444 |
"selser [[4,0,0,0,3,2,0,3,0,3,0]]": "ltebnx\n<br title/>\n4nzjam\n<br title=bar /><br title=bar/><br title=bar/ >", |
| 445 |
"selser [[3,0,3,0,2,0,3,3,0,2,0]]": "\n431wfo<br title/ >\n<br title=bar/>1qb15x8\n<br title=bar/ >" |
| 446 |
}, |
| 447 |
"Handling html with a div self-closing tag": { |
| 448 |
"wt2html": "<div title=\"\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[0,13,13,0]}'></div>\n<div title=\"\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[14,26,12,0]}'></div>\n<div title=\"\" data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[27,93,13,0]}'>\n<div title=\"bar\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[41,58,17,0]}'></div>\n<div title=\"bar\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[59,75,16,0]}'></div>\n<div title=\"bar/\" data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[76,93,17,0]}'></div></div>", |
| 449 |
"wt2wt": "<div title=\"\" />\n<div title=\"\" />\n<div title=\"\">\n<div title=\"bar\" />\n<div title=\"bar\" />\n<div title=\"bar/\">", |
| 450 |
"html2wt": "<div title=\"\">\n<div title=\"\">\n<div title=\"\">\n<div title=\"bar\">\n<div title=\"bar\">\n<div title=\"bar/\"></div></div></div></div></div></div>", |
| 451 |
"selser [0,0,4,0,1]": "<div title />\n9nb93f\n<div title=\"\" data-foobar=\"usk7dv\">\n<div title=\"bar\" />\n<div title=\"bar\" />\n<div title=\"bar/\">", |
| 452 |
"selser [0,2,3,0,1]": "<div title />1nmkreh\n\n<div title=\"\" data-foobar=\"yojiah\">\n<div title=\"bar\" />\n<div title=\"bar\" />\n<div title=\"bar/\">", |
| 453 |
"selser [0,2,0,2,[0,1,2,4,3,1]]": "<div title />1udkoch\n<div title/>gud5w8\n<div title=\"\">\n<div title=\"bar\" data-foobar=\"1s0ve99\" />1p544xk\nohnnt9<div title=\"bar/\" data-foobar=\"44kyov\">", |
| 454 |
"selser [4,0,0,0,[2,2,0,0,0,2]]": "ur1nlu\n<div title/>\n<div title/ >1xht7bz\n121vj7s<div title=bar />\n<div title=bar/>\nppklk1<div title=bar/ >", |
| 455 |
"selser [0,0,1,0,3]": "<div title />\n<div title=\"\" data-foobar=\"1t98n8c\" />\n", |
| 456 |
"selser [0,0,1,4,2]": "<div title />\n<div title=\"\" data-foobar=\"85erzc\" />1dvka01\n\n7oby7y<div title/ >\n<div title=bar />\n<div title=bar/>\n<div title=bar/ >", |
| 457 |
"selser [3,3,0,3,[0,0,4,0,0,4]]": "<div title/><div title/ >\n<div title=bar />194mu5t<div title=bar/>\n1fisrta\n", |
| 458 |
"selser [0,4,0,2,2]": "<div title />c3t99l<div title/>1fvy3dz\n1x4e84e<div title/ >\n<div title=bar />\n<div title=bar/>\n<div title=bar/ >", |
| 459 |
"selser [0,2,4,0,3]": "<div title />2i7ut3\n1sfaz9e\n", |
| 460 |
"selser [0,0,4,3,3]": "<div title />\n50n0e1", |
| 461 |
"selser [0,0,0,2,4]": "<div title />\n<div title/>1y4ezss\n1n0zzbf", |
| 462 |
"selser [0,3,1,0,4]": "<div title /><div title=\"\" data-foobar=\"1jg0isr\" />\nohye8s", |
| 463 |
"selser [0,3,0,4,1]": "<div title /><div title/>140npl1<div title=\"\" data-foobar=\"1x8zh9h\">\n<div title=\"bar\" />\n<div title=\"bar\" />\n<div title=\"bar/\">", |
| 464 |
"selser [2,4,0,0,[0,1,4,0,2,0]]": "1igs6jr<div title />1uh5dv3<div title/>\n<div title/ >\n<div title=\"bar\" data-foobar=\"1mczt4n\" />1bxeyc6<div title=bar/>lbstrg\n<div title=bar/ >", |
| 465 |
"selser [0,3,3,3,3]": "<div title />", |
| 466 |
"selser [2,3,4,2,[2,0,0,0,0,3]]": "16rdl5f<div title />c68aku\n\nail6mh\n<div title=\"\">72274k\n<div title=\"bar\" />\n<div title=\"bar\" />\n", |
| 467 |
"selser [0,4,3,0,[3,0,0,0,0,0]]": "<div title />13sh9ml\n<div title=\"\"><div title=\"bar\" />\n<div title=\"bar\" />\n<div title=\"bar/\">", |
| 468 |
"selser [1,0,0,0,4]": "<div title=\"\" data-foobar=\"1waijm\" />\n<div title/>\n6aojz3", |
| 469 |
"selser [0,0,4,0,0]": "<div title />\n1ex0bbl\n<div title/ >\n<div title=bar />\n<div title=bar/>\n<div title=bar/ >", |
| 470 |
"selser [0,0,3,0,2]": "<div title />\n\n63m27w<div title/ >\n<div title=bar />\n<div title=bar/>\n<div title=bar/ >" |
| 471 |
}, |
| 472 |
"Handling of %0A in URLs": { |
| 473 |
"html2wt": "* irc://%0Aa" |
| 474 |
}, |
| 475 |
"Handling of 
 in URLs": { |
| 476 |
"html2wt": "* irc://
a" |
| 477 |
}, |
| 478 |
"Horizontal ruler (should it add that extra space?)": { |
| 479 |
"wt2wt": "<hr>\n<hr>\nfoo <hr> bar", |
| 480 |
"html2wt": "<hr>\n<hr>\nfoo <hr> bar", |
| 481 |
"selser [2,2,4,2,3,[3]]": "2jn92h<hr>743cw1\ns9njeh\n\nzgot2i\n\n\nfoo \n\n", |
| 482 |
"selser [2,2,0,1,0,2]": "k89ks8<hr>5bkxh5\n<hr >\nfoo <hr\n>5qjne9\n\n bar", |
| 483 |
"selser [3,0,4,1,0,1]": "\neih5oh\n\nfoo <hr\n> bar", |
| 484 |
"selser [0,4,3,4,2,[3]]": "<hr>bsnj98\n\n1p6wqlp\n\n7rzgy0<hr\n>", |
| 485 |
"selser [2,0,0,1,4,2]": "1iulimo<hr>\n<hr >\nfoo \n\neo5myy\n\n1m11uh9\n\n bar", |
| 486 |
"selser [1,4,3,0,0,4]": "<hr data-foobar=\"8cspvg\">1hmmmf0\n\n\nfoo <hr\n>133sql4", |
| 487 |
"selser [1,0,0,[3],0,4]": "<hr data-foobar=\"opp9wd\">\n<hr ><hr\n>zwqkkb", |
| 488 |
"selser [2,3,0,0,4,3]": "i7wx9z<hr><hr >\nfoo \n\n16sq1tv", |
| 489 |
"selser [0,4,1,4,0,[4]]": "<hr>b1nzrd<hr data-foobar=\"165zhtw\">1k4chw0<hr\n>1q6lu5a", |
| 490 |
"selser [3,3,1,0,0,0]": "<hr data-foobar=\"2xzvqu\">\nfoo <hr\n> bar", |
| 491 |
"selser [4,0,0,3,2,3]": "1nk6z4b\n<hr >1wwxskq<hr\n>", |
| 492 |
"selser [1,3,0,2,0,[4]]": "<hr data-foobar=\"27wjn6\"><hr >1iad5xw\n\n\nfoo <hr\n>1ji7317", |
| 493 |
"selser [0,0,0,0,4,[2]]": "<hr>\n<hr >\nfoo \n\n19jorw0\n\n575z1a bar", |
| 494 |
"selser [3,4,4,1,3,0]": "nl6dc9\n\n131am6h\n\nfoo \n\n bar", |
| 495 |
"selser [0,0,0,4,0,[3]]": "<hr>\n<hr >1i8gtez<hr\n>", |
| 496 |
"selser [0,0,0,2,4,1]": "<hr>\n<hr >1yblofv\n\n\nfoo \n\n1q3eco8\n\nbar" |
| 497 |
}, |
| 498 |
"Horizontal ruler -- Supports content following dashes on same line": { |
| 499 |
"selser [0,2]": "----uv4ix9\n\n Foo", |
| 500 |
"selser [3,0]": " Foo", |
| 501 |
"selser [1,2]": "----1o60zkj\n\n Foo" |
| 502 |
}, |
| 503 |
"Horizontal ruler -- eats additional dashes on the same line": { |
| 504 |
"html2wt": "----" |
| 505 |
}, |
| 506 |
"Ignore pipe between table row attributes": { |
| 507 |
"wt2wt": "{|\n|quux\n|- id=\"foo\" style=\"color: red\" |\n|bar\n|}", |
| 508 |
"html2wt": "{|\n|quux\n|- id=\"foo\" style=\"color: red\"\n|bar\n|}", |
| 509 |
"selser [1]": "{| data-foobar=\"12tg6dr\"\n|quux\n|- id=foo | style='color: red'\n|bar\n|}", |
| 510 |
"selser [[0,1]]": "{|\n|quux\n|- id=foo | style='color: red'\n|bar\n|}", |
| 511 |
"selser [2]": "qqf7sy\n{|\n|quux\n|- id=foo | style='color: red'\n|bar\n|}", |
| 512 |
"selser [[2,2]]": "{|<!--3zapkf-->\n<!--12le581-->|quux\n|- id=foo | style='color: red'\n|bar\n|}", |
| 513 |
"selser [[4,2]]": "{|<!--1whfqxl--><!--zxj2in-->\n|quux\n|- id=foo | style='color: red'\n|bar\n|}", |
| 514 |
"selser [[3,2]]": "{|<!--19fpekv-->\n|quux\n|- id=foo | style='color: red'\n|bar\n|}" |
| 515 |
}, |
| 516 |
"Incorrecly removing closing slashes from correctly formed XHTML": { |
| 517 |
"html2html": "\n\n", |
| 518 |
"html2wt": "\n\n" |
| 519 |
}, |
| 520 |
"Indent and comment before table row": { |
| 521 |
"html2wt": "{|\n <!--hi-->|-\n | there\n|}" |
| 522 |
}, |
| 523 |
"Indented table with an empty td": { |
| 524 |
"html2wt": "{|\n|\n|foo\n|}" |
| 525 |
}, |
| 526 |
"Indented table with blank lines in between (T85627)": { |
| 527 |
"selser [2,[0,[[[0,4,3]]]]]": "53zi99 \n{|\n |foo\nww3fks \n|}", |
| 528 |
"selser [0,[0,[[[0,0,2]]]]]": " {|\n |foo\n \n \n1w3cp3e\n |}" |
| 529 |
}, |
| 530 |
"Inline HTML vs wiki block nesting": { |
| 531 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,17,0,0]}'><b data-parsoid='{\"stx\":\"html\",\"autoInsertedEnd\":true,\"dsr\":[0,17,3,0]}'>Bold paragraph</b></p><b data-parsoid='{\"stx\":\"html\",\"autoInsertedStart\":true,\"autoInsertedEnd\":true,\"dsr\":[17,37,0,0]}'>\n\n<p data-parsoid='{\"dsr\":[19,37,0,0]}'>New wiki paragraph</p></b>", |
| 532 |
"html2wt": "'''Bold paragraph'''\n\nNew wiki paragraph\n" |
| 533 |
}, |
| 534 |
"Inline wiki vs wiki block nesting": { |
| 535 |
"wt2wt": "'''Bold paragraph'''\n\nNew wiki paragraph", |
| 536 |
"html2wt": "'''Bold paragraph'''\n\nNew wiki paragraph\n", |
| 537 |
"selser [2,0,1]": "18hvqx8\n\n'''Bold paragraph\n\nNew wiki paragraph", |
| 538 |
"selser [0,0,[3]]": "'''Bold paragraph\n\n", |
| 539 |
"selser [1,3,[3]]": "'''Bold paragraph\n\n", |
| 540 |
"selser [0,0,4]": "'''Bold paragraph\n\njs14js", |
| 541 |
"selser [0,3,[4]]": "'''Bold paragraph\n\ni5pa1", |
| 542 |
"selser [[2],4,2]": "19nmwq1'''Bold paragraph\n\ndh4zbb\n\nbwvwda\n\nNew wiki paragraph", |
| 543 |
"selser [0,0,2]": "'''Bold paragraph\n\n10pnlgs\n\nNew wiki paragraph" |
| 544 |
}, |
| 545 |
"Internal link with is link trail and link prefix": { |
| 546 |
"html2wt": "[[Mótmælendatrú|xxxar]]\n[[Mótmælendatrú|mótmælendatrúar]]\n[[Söfnuður|mótmælendasöfnuður]]\n[[Söfnuður|mótmælendasöfnuðir]]\n[[Söfnuður|mótmælendasöfnuðirxxx]]\n" |
| 547 |
}, |
| 548 |
"Link containing an ampersand": { |
| 549 |
"selser [1,4,1,0,[3,0,0]]": "[[Foo & bar]]\n\n10hs1hv\n\n[[Foo & bar]]\n\n&amp; bar]]", |
| 550 |
"selser [4,4,1,0,4]": "1t90bln\n\nin61qw\n\n[[Foo & bar]]\n\n18k6kii", |
| 551 |
"selser [3,2,[[3]],2,[3,0,0]]": "q9fai7\n\n1k0d3dg\n\n&amp; bar]]", |
| 552 |
"selser [2,2,1,4,0]": "756eqn\n\n[[Foo & bar]]\n\n1q3qdhc\n\n[[Foo & bar]]\n\n1c6bj2m\n\n[[Foo &amp; bar]]" |
| 553 |
}, |
| 554 |
"Link with double quotes in title part (literal) and alternate part (interpreted)": { |
| 555 |
"selser [[[[[3]]]],0,[4],0,[[3]],3,2]": "[[File:Denys_Savchenko_''Pentecoste''.jpg]]\n\n1o8xlu6\n\n141oc9a\n\n[[''Pentecoste''|''Pentecoste'']]" |
| 556 |
}, |
| 557 |
"Link with suffix": { |
| 558 |
"html2wt": "[[Main Page|Main Pagexxx]], [[Main Page]]XXX, [[Main Page]]!!!\n" |
| 559 |
}, |
| 560 |
"List interrupted by empty line or heading": { |
| 561 |
"html2wt": "* foo\n\n** bar\n\n== A heading ==\n\n* Another list item" |
| 562 |
}, |
| 563 |
"List items are not parsed correctly following a <pre> block (T2785)": { |
| 564 |
"html2wt": "* <pre>foo</pre>\n* <pre>bar</pre>\n* zar" |
| 565 |
}, |
| 566 |
"List items from template": { |
| 567 |
"html2wt": "{{inner list}}\n*item 2\n\n* item 0\n{{inner list}}\n* item 2\n\n* item 0\n* notSOL{{inner list}}\n* item 2" |
| 568 |
}, |
| 569 |
"Magic variable as template parameter": { |
| 570 |
"html2wt": "This is a test template with parameter MediaWiki\n" |
| 571 |
}, |
| 572 |
"Mixed list": { |
| 573 |
"html2wt": "* Mixed list\n*# with numbers\n** and bullets\n*# and numbers\n* bullets again\n** bullet level 2\n*** bullet level 3\n***# Number on level 4\n** bullet level 2\n**# Number on level 3\n**# Number on level 3\n*# number level 2\n* Level 1\n*** Level 3\n\n#** Level 3, but ordered\n", |
| 574 |
"selser [3,0,0]": "#**Level 3, but ordered" |
| 575 |
}, |
| 576 |
"Mixing markup for italics and bold": { |
| 577 |
"wt2wt": "'<nowiki/>''bold'<nowiki/>'''''bold''bolditalics'''''", |
| 578 |
"html2wt": "'<nowiki/>''bold'<nowiki/>'''''bold''bolditalics'''''\n", |
| 579 |
"selser [1]": "'<nowiki/>''bold''''''bold''bolditalics'''''", |
| 580 |
"selser [2]": "1e1nuk\n\n'''bold''''''bold''bolditalics'''''", |
| 581 |
"selser [[0,0,[4,[4]]]]": "'<nowiki/>''bold''''''114rtf8''1rf8z0c'''''", |
| 582 |
"selser [[0,2,1]]": "'jesq0d''bold''''''bold''bolditalics'''''" |
| 583 |
}, |
| 584 |
"Multiple newlines after tables are converted to p-br-p tags": { |
| 585 |
"selser [2,0,[2,2],0,2,2,3]": "1vlvcem\n{|\n|x\n|}\nh7tgjz\ngwxfxn\n1rr9v1k\n\n\n\n\nf2i27b\n", |
| 586 |
"selser [3,4,2,4,[2,0],0,0]": "q9y9ul\n\n1dzf6n0\n\n\n\n\n1c6ecgs\n\nzdayuv\n\n=b=", |
| 587 |
"selser [0,0,3,2,2,0,0]": "{|\n|x\n|}\n1gwrqpk\n\nqd1vqc\n\n\n\n=b=", |
| 588 |
"selser [[0,[2,0]],3,0,3,[4,0],4,[3]]": "{|\n<!--dp0ho3-->|x\n|}\n\n\nr5akja\n\nqy67r3", |
| 589 |
"selser [4,0,4,4,2,3,0]": "q19l6f\n\n1hwqo8z\n\n5mihjv\n\n1p6mg5l\n\n\n\n=b=", |
| 590 |
"selser [2,0,1,2,2,0,2]": "ooegna\n{|\n|x\n|}\n\n\n\n\n\nijxeva\n\n8ud2z2\n\n\n\n1x17gwd\n\n=b=", |
| 591 |
"selser [[0,[1,0]],4,[0,1],2,0,2,0]": "{|\n|x\n|}\n5dmvt7\n\n\n\n1lb803i\n\n\n\n\n1x89ymj\n\n=b=", |
| 592 |
"selser [[3,[[4],0]],0,2,2,[4,2],4,3]": "{|\n|1qkry9z\n|}\nzhprdg\n\n\n\n\n140x1kp\n\ntomszg1k83zbt\n\ngp6sy2", |
| 593 |
"selser [3,0,0,2,0,0,0]": "\n\n\n\n1r9koth\n\n\n\n=b=" |
| 594 |
}, |
| 595 |
"Namespace (lang=de) Benutzer Diskussion {{ns:3}}": { |
| 596 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,8,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,8,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"ns:3\",\"function\":\"ns\"},\"params\":{},\"i\":0}}]}'>3</span></p>", |
| 597 |
"html2wt": "Benutzer Diskussion\n" |
| 598 |
}, |
| 599 |
"Namespace (lang=de) Benutzer {{ns:User}}": { |
| 600 |
"html2wt": "Benutzer\n" |
| 601 |
}, |
| 602 |
"Namespace File {{ns:File}}": { |
| 603 |
"html2wt": "File\n" |
| 604 |
}, |
| 605 |
"Namespace File {{ns:Image}}": { |
| 606 |
"html2wt": "File\n" |
| 607 |
}, |
| 608 |
"Namespace User talk {{ns:User_talk}}": { |
| 609 |
"html2wt": "User talk\n" |
| 610 |
}, |
| 611 |
"Namespace User talk {{ns:uSeR tAlK}}": { |
| 612 |
"html2wt": "User talk\n" |
| 613 |
}, |
| 614 |
"Namespace User {{ns:User}}": { |
| 615 |
"html2wt": "User\n" |
| 616 |
}, |
| 617 |
"Nested <noinclude>s": { |
| 618 |
"selser [4,0,[3,0,3,4,0],3,0]": "95w6d2\n\n<noinclude>k1e0sn\nz\n</noinclude>" |
| 619 |
}, |
| 620 |
"Nested lists 1": { |
| 621 |
"html2wt": "* foo\n** bar\n" |
| 622 |
}, |
| 623 |
"Nested lists 10 (list and span siblings: wt2wt regression)": { |
| 624 |
"html2wt": "* a <span>x</span>\n** b <span>y</span>\n" |
| 625 |
}, |
| 626 |
"Nested lists 11 (T262409: trailing whitespace & selser)": { |
| 627 |
"selser [[2]]": "* mi5h3i\n**a\n***b ", |
| 628 |
"selser [[1]]": "**a\n***b ", |
| 629 |
"selser [2]": "dz9syw\n**a\n***b ", |
| 630 |
"selser [[[2]]]": "*1sd3fyg\n**a\n***b ", |
| 631 |
"selser [1]": "**a\n***b ", |
| 632 |
"selser [[[1]]]": "**a\n***b ", |
| 633 |
"selser [[[[1]]]]": "**a\n***b ", |
| 634 |
"selser [[[[[3,0]]]]]": "***b " |
| 635 |
}, |
| 636 |
"Nested lists 2": { |
| 637 |
"html2wt": "** foo\n* bar" |
| 638 |
}, |
| 639 |
"Nested lists 3 (first element empty)": { |
| 640 |
"wt2wt": "\n**bar\n", |
| 641 |
"html2wt": "\n** bar\n", |
| 642 |
"selser [2]": "1b8vuw9\n*\n**bar", |
| 643 |
"selser [1]": "*\n**bar", |
| 644 |
"selser [[1]]": "*\n**bar", |
| 645 |
"selser [[[0,[[3]]]]]": "*\n**", |
| 646 |
"selser [[[0,[1]]]]": "*\n**bar", |
| 647 |
"selser [[2]]": "* 1yzerqh\n*\n**bar" |
| 648 |
}, |
| 649 |
"Nested lists 4 (first element empty)": { |
| 650 |
"html2wt": "**\n* bar" |
| 651 |
}, |
| 652 |
"Nested lists 6 (both elements empty)": { |
| 653 |
"wt2wt": "\n**\n", |
| 654 |
"html2wt": "\n**\n", |
| 655 |
"selser [1]": "*\n**", |
| 656 |
"selser [2]": "1u5v0i7\n*\n**", |
| 657 |
"selser [[[0,1]]]": "*\n**", |
| 658 |
"selser [[1]]": "*\n**", |
| 659 |
"selser [[2]]": "* 14d3cex\n*\n**" |
| 660 |
}, |
| 661 |
"Nested lists 7 (skip initial nesting levels)": { |
| 662 |
"html2wt": "*** foo\n" |
| 663 |
}, |
| 664 |
"Nested lists 8 (multiple nesting transitions)": { |
| 665 |
"html2wt": "* foo\n*** bar\n** baz\n* boo" |
| 666 |
}, |
| 667 |
"Nested template calls": { |
| 668 |
"html2wt": "(My parameter is: param)\n" |
| 669 |
}, |
| 670 |
"Non-breaking spaces in title": { |
| 671 |
"html2wt": "[[ Main Page ]]\n" |
| 672 |
}, |
| 673 |
"Non-empty attributes in th-cells": { |
| 674 |
"html2wt": "{|\n!Foo\n! style=\"color: red\" |Bar\n|}" |
| 675 |
}, |
| 676 |
"Non-word characters don't terminate tag names (T19663, T42670, T54022)": { |
| 677 |
"wt2wt": "<blockquote|>a\n\n<b→> doesn't terminate </b→>\n\n<bä> doesn't terminate </bä>\n\n<boo> doesn't terminate </boo>\n\n<s.foo> doesn't terminate </s.foo>\n\n<sub-ID#1>", |
| 678 |
"html2wt": "<blockquote|>a\n\n<b→> doesn't terminate </b→>\n\n<bä> doesn't terminate </bä>\n\n<boo> doesn't terminate </boo>\n\n<s.foo> doesn't terminate </s.foo>\n\n<sub-ID#1>\n", |
| 679 |
"selser [0,0,0,3,0,4,1,3,[3],0,[2]]": "<blockquote|>a</blockquote>\n\n<b→> doesn't terminate </b→>\n\n<bä> doesn't terminate </bä>\n\ng0p38s\n\n<boo> doesn't terminate </boo>\n\n\n15zmhzp<sub-ID#1>", |
| 680 |
"selser [0,0,[3],4,3,0,1,4,[4],0,0]": "<blockquote|>a</blockquote>\n\n\n10u9srl\n\n<boo> doesn't terminate </boo>\n\n1pfxe03\n\n17gvfiq\n\n<sub-ID#1>", |
| 681 |
"selser [2,0,0,2,1,0,[4],0,0,0,[3]]": "1kvfbh7\n\n<blockquote|>a</blockquote>\n\n<b→> doesn't terminate </b→>\n\n1ckx0ef\n\n<bä> doesn't terminate </bä>\n\n1euhok7\n\n<s.foo> doesn't terminate </s.foo>\n\n", |
| 682 |
"selser [4,3,2,0,4,4,1,2,[3],3,0]": "xkwlxr\n\noglbw8\n\n<b→> doesn't terminate </b→>\n\n1idx6c7\n\n12q9nwh\n\n<boo> doesn't terminate </boo>\n\nh6uxwa\n\n<sub-ID#1>", |
| 683 |
"selser [2,4,1,0,[2],0,0,0,[4],3,2]": "1jnsohs\n\n<blockquote|>a</blockquote>\n\nmsvqr8\n\n<b→> doesn't terminate </b→>\n\n1blzxen<bä> doesn't terminate </bä>\n\n<boo> doesn't terminate </boo>\n\n1q0c8fj\n\ndk8akl\n\n<sub-ID#1>", |
| 684 |
"selser [0,0,2,2,3,3,3,4,3,0,1]": "<blockquote|>a</blockquote>\n\n1ego5dv\n\n<b→> doesn't terminate </b→>\n\n1bkybqx\n\nn2r4nj\n\n<sub-ID#1>", |
| 685 |
"selser [0,4,2,0,4,4,1,0,0,2,[2]]": "<blockquote|>a</blockquote>\n\n1vd24n8\n\n18ssbe9\n\n<b→> doesn't terminate </b→>\n\n1yjt8s3\n\nn9g45c\n\n<boo> doesn't terminate </boo>\n\n<s.foo> doesn't terminate </s.foo>\n\n1qy93z2\n\niaid67<sub-ID#1>" |
| 686 |
}, |
| 687 |
"Normalizations should be restricted to edited content": { |
| 688 |
"selser [2,0,0,2,3]": "qnd1q4\n\na\n= =\nzvmmb4\n", |
| 689 |
"selser [0,4,0,0,3]": "a\n\n1b27ypv\n\n= =\n", |
| 690 |
"selser [3,0,0,3,[2]]": "\n= =\n158zbx1b", |
| 691 |
"selser [0,4,0,0,0]": "a\n\ncs5h4n\n\n= =\nb", |
| 692 |
"selser [2,2,0,4,3]": "1u9m45m\n\na\n\n1wk6xex\n\n= =\nm4bj9", |
| 693 |
"selser [[4],0,2,2,4]": "4zaulx\n\n8lgr3b\n\n= =\nq57o1d\n1yj3afc", |
| 694 |
"selser [3,2,0,3,4]": "71i7pu\n\n= =\n1aurpu1", |
| 695 |
"selser [0,0,2,0,[3]]": "a\n\n1d4voyj\n\n= =\n", |
| 696 |
"selser [3,4,0,2,3]": "1dbwger\n\n= =\np3hzk\n", |
| 697 |
"selser [1,2,0,4,4]": "a\n\n1k4ytql\n\n= =\n1tgll7o\n\nh7z05y", |
| 698 |
"selser [1,2,0,0,0]": "a\n\n1qeflfy\n\n= =\nb", |
| 699 |
"selser [1,2,2,3,0]": "a\n\n1sud6qp\n\n1suxewc\n\n= =\nb" |
| 700 |
}, |
| 701 |
"Numbered list": { |
| 702 |
"html2wt": "# Numbered list\n# item 2\n# item 3" |
| 703 |
}, |
| 704 |
"PAGESINCATEGORY invalid title fatal (r33546 fix)": { |
| 705 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,27,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,27,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"PAGESINCATEGORY:<bogus>\",\"function\":\"pagesincategory\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_pagesincategory missing in Parsoid.</span></p>", |
| 706 |
"html2wt": "0\n" |
| 707 |
}, |
| 708 |
"Paragraphs inside blockquotes/divs (extra line break on close)": { |
| 709 |
"html2wt": "<blockquote><div>Line one\nLine two\n\n</div></blockquote>" |
| 710 |
}, |
| 711 |
"Paragraphs inside blockquotes/divs (extra line break on open and close)": { |
| 712 |
"html2wt": "<blockquote><div>\nLine one\n\nLine two\n\n</div></blockquote>" |
| 713 |
}, |
| 714 |
"Paragraphs inside blockquotes/divs (no extra line breaks)": { |
| 715 |
"html2wt": "<blockquote><div>Line one\nLine two</div></blockquote>" |
| 716 |
}, |
| 717 |
"Paragraphs inside divs (extra line break on close)": { |
| 718 |
"html2wt": "<div>Line one\nLine two\n\n</div>" |
| 719 |
}, |
| 720 |
"Paragraphs inside divs (extra line break on open and close)": { |
| 721 |
"html2wt": "<div>\nLine one\n\nLine two\n\n</div>" |
| 722 |
}, |
| 723 |
"Paragraphs inside divs (no extra line breaks)": { |
| 724 |
"html2wt": "<div>Line one\nLine two</div>" |
| 725 |
}, |
| 726 |
"Paragraphs with extra newline spacing": { |
| 727 |
"selser [2,2,1,0,[2,0,2],4,3,4,2,0,4,0,2]": "1p5wgdu\n\na\n\n1uqq7s6\n\nb (+2 nls)\n\nm0j4wq\nnlwdwp\nc (+3 nls)\n\n225o51\n\nkvvcz0\n\n15qp921\n\nd (+4 nls)\n\n13921h6\n\nlw982u\n\n\n\ne (+5 nls)", |
| 728 |
"selser [3,0,0,2,3,0,4,2,3,0,0,0,1]": "\nb (+2 nls)\n\nh3cghw\n\nvxaa29\n\n1v4qexx\n\n\n\n\n\ne (+5 nls)", |
| 729 |
"selser [[3],4,2,3,[3,0,0],3,[0,3],0,2,2,2,4,1]": "\n\n1xs9ccj\n\n1muasc3\n\nb (+2 nls)\n\n\n\nc (+3 nls)\n\no9cnyn\n\nd (+4 nls)\n\n12t0g19\n\n137115n\n\n\n\n\n1i8cxso\n\n\ne (+5 nls)", |
| 730 |
"selser [1,2,2,0,1,2,[0,1],3,2,0,3,0,2]": "a\n\nqbbefq\n\n7k45lz\n\nb (+2 nls)\n\n\nc (+3 nls)\n\n1gjxhrm\n\n\n\nskkv54\n\nd (+4 nls)\n\nzbx540\n\n\n\ne (+5 nls)", |
| 731 |
"selser [[4],4,[4],4,[0,3,4],4,0,0,[4],4,1,0,[3,0,0]]": "1xi6isp\n\n1p0ixdc\n\nrydgo2\n\n1i46z59\n\n654q2q\n\n1icytnk\n\n\n\n\ng08e2h\n\nzsz1s8\n\n\n\n\ne (+5 nls)", |
| 732 |
"selser [0,2,1,3,[0,0,3],2,0,0,4,4,4,3,2]": "a\n\nypbs9h\n\nb (+2 nls)\n\n\n\n17acb57\n\n\n\n\n8joa2d\n\nvplse6\n\nxpcb8a\n\nbq3uom\n\n\n\ne (+5 nls)", |
| 733 |
"selser [1,2,0,2,[0,4,0],0,0,0,[4],3,[3,0],2,[2,0,4]]": "a\n\n1h2md8m\n\nb (+2 nls)\n\n11c0qa4\n\nojrr5t\nc (+3 nls)\n\n\n\n\n8ahaal\n\n\n\n\n\n\n1ymqb8h\n\nkuadnh\n127xp8s", |
| 734 |
"selser [4,4,3,0,[2,2,0],0,4,4,[4],4,2,2,1]": "4yp5nn\n\n1nlaulh\n\nnz5tdw\n6tela6\nc (+3 nls)\n\na4vab1\n\nvpvfk2\n\n1vg1wi1\n\n16s65vs\n\n1ptiiwx\n\n\n\n\n6phwxb\n\n\ne (+5 nls)", |
| 735 |
"selser [3,0,4,3,[0,0,4],2,4,3,0,0,1,0,3]": "\n1s3o2oi\n\n\n\n\n1gxx3km\n\n1omx16r\n\n17a0znt\n\nd (+4 nls)\n\n\n", |
| 736 |
"selser [3,4,3,0,[0,0,3],3,0,3,2,0,3,4,[0,0,2]]": "13xe03t\n\n\n\n\n\n\n3ghcnp\n\nd (+4 nls)\n\n1j6rd6g\n\n\n1ddbx3x\ne (+5 nls)", |
| 737 |
"selser [[2],0,1,0,2,0,[4,0],3,[3],0,3,3,[3,4,2]]": "ytq2bba\n\nb (+2 nls)\n\nsq90h2\n\n\n\nc (+3 nls)\n\nv77kui\n\n\nbchjcm1k9m205\ne (+5 nls)" |
| 738 |
}, |
| 739 |
"Paragraphs with newline spacing with comment lines in between": { |
| 740 |
"html2wt": "----\na\nb\n\n----\na\nb\n\n----\na\nb\n\n----\na\n\nb\n\n----\na\n\nb\n\n----\na\n\n\nb\n\n----\na\n\n\nb\n\n----", |
| 741 |
"selser [4,3,3,0,3,2,[0,4,0,0],0,0,0,[3,0,2,0,0,0,0],2,2,0,4,0,4,0,[2],0,2,0,[3],0,0,0,2,0,0,0,0,3,2,0,2,2,3,2,2,2,1,3,0]": "4idmdg\n\nv1u4kj\n\na\n19flyu<!--More than 1 comment, still stripped-->\nb\n----\n<!--foo-->yhh6od <!----> <!-- bar --> \nb\n\n1vzwza1\nksuej1\n----\n533jg6\n\n18693a9\n\n1b1zzq2b\n1j4oogd\n----\na\n\n<!--foo-->\npiqwm7\n\nb\n----\na\n\nsi4rzz<!--foo-->\n\noq15o2\n\n\n\nb\n\n1u7gllo\n\n1l7j2hn\n\n1hp408e\n\na\n\nug0tqu\n\n\n<!--foo-->\nb\n----", |
| 742 |
"selser [1,2,3,0,0,2,[3,3,0,0],2,0,0,[4,0,4,0,0,4,3],4,0,3,1,3,4,0,[3],0,0,2,2,3,0,0,[2],0,3,0,[3],2,0,0,2,0,0,4,3,0,4,2,0]": "----kur8nv\n\n----1kgil6l\n<!--More than 1 comment, still stripped-->\nb\n\n9nm1fb\n----\n1g5hu4w<!--foo-->xc83vu<!----> 27n7tk\n\ndvmogw\n----a\n\n5w3avv\n\n----1pv6hwb\n3fto9i\n\na<!--foo-->\n\nxmhxk3b\n\n\n1e1n2gp\n<!--foo-->\n\nudauta\n\n\n\nb\n----1ytgmp5\nt5r6mc\n\n1neouug\n----", |
| 743 |
"selser [0,0,2,0,0,3,0,0,4,0,[4,0,2,0,0,0,3],0,0,0,1,0,0,0,2,0,0,0,3,0,0,0,[2],0,2,0,3,0,0,4,2,3,3,2,0,4,2,0,2]": "----\nugqg84\n\na\n<!--foo-->\nb\n----a\n<!--foo--><!--More than 1 comment, still stripped-->\nb\n8a8i4f\n\n14p3eym<!--foo-->5k6xgo <!----> <!-- bar -->\n----\na\n<!--foo-->\n\nj4kzgd\n\nb\n----\n\n<!--foo-->\niel4beb\n1idp93\n----\n\n<!--foo-->10fyx94\n\nreu5h9\n\n\n\nb\n\n19sgszs\n\na\n\n1ux3wa1\n\n15knlnd\n\n\n\n<!--foo-->\nb\n1nos462\n----", |
| 744 |
"selser [0,0,[2,2,3],0,3,3,0,0,2,4,[0,0,3,2,2,0,2],2,3,4,1,4,0,0,[3],0,2,4,2,2,4,4,0,0,0,0,2,0,2,2,1,3,1,3,4,2,2,0,0]": "----\n8iqt3ba\n18t9xnl<!--foo-->\n\na\n<!--foo--><!--More than 1 comment, still stripped-->\nb\ng5g4wq\n----19z39mj\n\na\n<!--foo-->1lxz6r6<!---->1avra4v <!-- bar -->1jnnr7 \nb\n\n1y1n5cj\n\n1baofm9\n\na\n\n1vdumlm<!--foo-->\n\n\nze3288\n----z4w7so\n\n1oyvpzk\n\na\n\na8olhi\n\n1r0h0ai\n\n1pj4344\n\nb\n----\nyhdpga\n\na\n\nie2pvd<!--foo-->\n\nljbyvk\n\n\nb\n----1wf7d0l\n\n9aers9\nyfi9gw\n\n\n\n<!--foo-->\nb\n----", |
| 745 |
"selser [0,0,[3,0,2],0,0,0,[0,0,3,2],3,0,3,3,0,3,3,3,2,3,0,4,0,0,3,0,3,0,2,4,0,0,0,[3],0,3,3,2,3,0,0,[3],0,0,3,0]": "----\n<!--foo-->1cfe1r9\nb\n----\na\n<!--foo-->1kv89hz\nb\n----\nrecajl\n\niz11ly\n----a<!--foo-->tnuwbs\n\n1knfzvl\n----\n\n\n16neghi\n\n\n\nb\n----\n\n\n\n<!--foo-->\nb\n----", |
| 746 |
"selser [0,3,3,2,4,0,3,2,4,3,[0,3,4,0,0,2,0],4,0,0,1,0,0,2,2,3,0,3,0,0,3,0,4,3,2,2,4,4,4,0,3,2,0,0,4,0,0,0,1]": "----1f66zr4\nn47tnq\n\n5jmuqp\n\n1r4xzcd\n\na\n1hn4lv<!----> 83rtdb<!-- bar --> \nb\n\n1kt0p1m\n----\na\n<!--foo-->\njs6wu\n\n10xch7v\n\nb\n----a\n\n943gpk\n\n1x4bitf\n----s1in1u\n13s4qy4\n\n1lv6da1\n\nlv0j52\n\n14zly32\n----\nhh4p2m\n\n\n\n<!--foo-->\nb\n----" |
| 747 |
}, |
| 748 |
"Paragraphs with newline spacing with non-empty mixed comment and white-space lines in between": { |
| 749 |
"html2wt": "----\na\nb\n\n----\na\nb\n\n----\na\n\nb\n\n----\na\n \n\nb\n\n----", |
| 750 |
"selser [0,3,[0,4,2],3,1,0,1,0,0,4,2,3,0,2,0,2,0,3,0,3,[3],2,2,0,3]": "----a\nsgci4lkkecrw\nb\n----\na\n <!--foo--><!--More than 1 comment doesn't disable stripping of this line!-->\nb\n----ijh0ts\n\n9a6gc5\n\na<!--foo-->decf0j\n <!--bar-->\na76vx8\nb\n----\n\n\nlj3p7b\nfd5g6h\n\n\n <!--foo-->\n <!--bar-->\n \nb\n", |
| 751 |
"selser [0,0,2,0,0,3,4,0,0,0,1,3,0,0,3,3,[4],0,2,2,0,2,2,0,0]": "----\nd03a05\n\na\n <!--foo-->\nb\n----1hhttf7\n----\na<!--foo-->\n \n1yoorrh\n1t1utlk\n----xbpuid\na\n\n7i21zg\n \n1q5ki3w\n\n\n <!--foo-->\n <!--bar-->\n \nb\n----" |
| 752 |
}, |
| 753 |
"Paragraphs with newline spacing with non-empty white-space lines in between": { |
| 754 |
"html2wt": "----\na\n\nb\n\n----\na\n \n\nb\n\n----", |
| 755 |
"selser [0,3,[4],3,0,3,0,3,2,0,2,3,0]": "----2y2wh0\n\nb\n----18j2y5c\n\na\naj5awq\n\n\n \nb\n----", |
| 756 |
"selser [0,0,1,0,[4],2,0,0,4,0,1,2,2]": "----\na\n \ng4unt5\n\n83ekqt\n----\n1rr1da8\n\n \n \nb\n\nd8t3up\n5smtg8\n----", |
| 757 |
"selser [2,0,[4],4,1,3,0,4,0,4,0,0,2]": "1l51hcq\n----\n1vm7egp\n\n1hrk1i2\n\nb\n----1olcgo3\n\na\n\nyz8wnq\n\n\n \nb\nj6et0b\n----", |
| 758 |
"selser [3,2,4,4,0,0,0,4,[4],0,2,3,2]": "kfvmkr\n\nzhj2dm\n\n1d8tvqj\n\nb\n----1pgs76x\n\n1cthmp7\n7y51dc\n\n\n \nb\n\nk284t3\n----", |
| 759 |
"selser [1,0,0,0,3,3,4,0,[4],0,[0,0,3],2,4]": "----\na\n \n1tcdcfc\n\n110qe1v\n \n \n\n\n\n1vozlr0\n\nuqg61g" |
| 760 |
}, |
| 761 |
"Parents of subpages, two levels up": { |
| 762 |
"selser [[[3],3],2,1]": "\nlhdwhe\n\n[[../../|L1]]l" |
| 763 |
}, |
| 764 |
"Parser Functions: 1. Simple example": { |
| 765 |
"html2wt": "FOO\n" |
| 766 |
}, |
| 767 |
"Parser Functions: 2. Nested use (only outermost should be marked up)": { |
| 768 |
"html2wt": "FOO\n" |
| 769 |
}, |
| 770 |
"Parsing an URL": { |
| 771 |
"html2wt": "http://fr.wikipedia.org/wiki/🍺\n", |
| 772 |
"selser [[[2]],2,0]": "[[:fr:🍺|1cq91rfhttp://fr.wikipedia.org/wiki/🍺]]\n\nszrdkt\n<!-- EasterEgg we love beer, better be able be able to link to it -->" |
| 773 |
}, |
| 774 |
"Parsing of overlapping (improperly nested) inline html tags": { |
| 775 |
"wt2wt": "<span><s>x</span>", |
| 776 |
"html2wt": "<span><s>x</s></span>\n", |
| 777 |
"selser [2]": "1mui2b\n\n<span><s>x</span></s>" |
| 778 |
}, |
| 779 |
"Parsing optional HTML elements (T8171)": { |
| 780 |
"html2wt": "{| \n | Some tabular data\n | More tabular data ...\n | And yet som tabular data \n|}" |
| 781 |
}, |
| 782 |
"Parsoid link trail escaping": { |
| 783 |
"html2html": "<p data-parsoid='{\"dsr\":[0,19,0,0]}'><a rel=\"mw:WikiLink\" href=\"./Apple?action=edit&redlink=1\" title=\"Apple\" class=\"new\" typeof=\"mw:LocalizedAttrs\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Apple\"},\"sa\":{\"href\":\"apple\"},\"dsr\":[0,9,2,2]}' data-mw-i18n='{\"title\":{\"lang\":\"x-page\",\"key\":\"red-link-title\",\"params\":[\"Apple\"]}}'>apple</a><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[9,18,9,0]}'></span>s</p>" |
| 784 |
}, |
| 785 |
"Parsoid should not accept invalid interwiki shortcuts": { |
| 786 |
"html2wt": "[[news:Foo|Foo]]\n[news:Foo Foo]\n[news:Foo Foo]" |
| 787 |
}, |
| 788 |
"Parsoid-centric test: Whitespace in ext- and wiki-links should be preserved": { |
| 789 |
"wt2wt": "[[Foo| bar]]\n\n[[Foo| ''bar'']]\n\n[http://wp.org foo]\n\n[http://wp.org ''foo'']", |
| 790 |
"html2wt": "[[Foo| bar]]\n\n[[Foo| ''bar'']]\n\n[http://wp.org foo]\n\n[http://wp.org ''foo'']\n", |
| 791 |
"selser [3,2,[[4,2]],3,4,3,2]": "2i1snz\n\n[[Foo|16tbpzj148o92k''bar'']]\n\n223sno\n\n19y3bzn\n\n[http://wp.org ''foo'']", |
| 792 |
"selser [0,3,1,0,1,0,1]": "[[Foo| bar]]\n\n[[Foo| ''bar'']]\n\n[http://wp.org foo]\n\n[http://wp.org ''foo'']", |
| 793 |
"selser [[[3]],4,3,4,[2],3,3]": "\n1t8ns1i\n\n1o1te3p\n\n1uxkvgv[http://wp.org foo]", |
| 794 |
"selser [[[2]],0,[[2,3]],3,4,4,0]": "[[Foo|vx7uar bar]]\n\n[[Foo|1s87bt2]]\n\n1bax44\n\n17mezoo\n\n[http://wp.org ''foo'']", |
| 795 |
"selser [[[3]],4,2,2,2,4,0]": "\n1bb3nq0\n\nn4ns6p\n\n[[Foo| ''bar'']]\n\n6g4kky\n\nuse10m\n\n[http://wp.org foo]\n\n18yuaf7\n\n[http://wp.org ''foo'']", |
| 796 |
"selser [2,0,[[0,3]],0,4,0,3]": "bynb0\n\n[[Foo| bar]]\n\n1s1uvua\n", |
| 797 |
"selser [2,4,[2],4,2,0,4]": "1g99wzg\n\n[[Foo| bar]]\n\ngubtp7\n\n1vs4tsb[[Foo| ''bar'']]\n\n70ua8g\n\n1tsq6qe\n\n[http://wp.org foo]\n\nccfjxu", |
| 798 |
"selser [3,0,1,3,0,0,[[[2]]]]": "\n[[Foo| ''bar'']]\n\n[http://wp.org foo]\n\n[http://wp.org ''paswhgfoo'']", |
| 799 |
"selser [2,4,2,0,[2],2,4]": "of8xbl\n\n[[Foo| bar]]\n\n18noozq\n\n139rkhq\n\n[[Foo| ''bar'']]\n\n16kx4cb[http://wp.org foo]\n\np6eisn\n\n1cgowhb", |
| 800 |
"selser [3,4,2,2,2,0,4]": "ex036k\n\n38b961\n\n[[Foo| ''bar'']]\n\n116wf43\n\nrpnam1\n\n[http://wp.org foo]\n\n9bk7he", |
| 801 |
"selser [0,2,1,3,[[4]],3,0]": "[[Foo| bar]]\n\n17tedga\n\n[[Foo| ''bar'']]\n\n[http://wp.org 1r1ldpn]\n\n[http://wp.org ''foo'']", |
| 802 |
"selser [3,4,4,2,2,4,0]": "qu9hey\n\nmxpnzr\n\nkk5on7\n\n15tt3s3\n\n[http://wp.org foo]\n\n19vr3au\n\n[http://wp.org ''foo'']" |
| 803 |
}, |
| 804 |
"Parsoid: Make sure nested lists are serialized on their own line even if HTML contains no newlines": { |
| 805 |
"html2wt": "# foo\n## bar\n\n* foo\n** bar\n\n: foo\n:: bar\n" |
| 806 |
}, |
| 807 |
"Parsoid: Page property magic word with magic word contents": { |
| 808 |
"metadata": "" |
| 809 |
}, |
| 810 |
"Parsoid: Template-generated DISPLAYTITLE": { |
| 811 |
"metadata": "" |
| 812 |
}, |
| 813 |
"Parsoid: unknown parser function (T314524)": { |
| 814 |
"selser [0,0,[3],0,2,0,3]": "{{#tag:b|This is a known parser function}}\nNow show the unknown parser functions for comparison.\n\nto6td\n\n{{#foo}}\n" |
| 815 |
}, |
| 816 |
"Piped link with comment in link text": { |
| 817 |
"html2wt": "[[Main Page|The Main Page]]\n" |
| 818 |
}, |
| 819 |
"Play a bit with r67090 and T5158": { |
| 820 |
"selser [0,2,1,3,0,0,1]": "<div style=\"width:50% !important\"> </div>yyzg2g\n<div style=\"width:50% !important\" data-foobar=\"338jos\"> </div>\n<div style=\"width:50% !important\"> </div>\n<div style=\"border : solid;\" data-foobar=\"1sol4wa\"> </div>" |
| 821 |
}, |
| 822 |
"Remove a list item but do not insert newline above list": { |
| 823 |
"selser [manual]": "header\n*foo\n\nfooter" |
| 824 |
}, |
| 825 |
"Render invalid page names as plain text (T53090)": { |
| 826 |
"wt2wt": "[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n<nowiki>[[foo~~~bar]]</nowiki>\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n[[{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}|bar]]\n[[{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}]]\n[[{{1x|foo>bar}}]]\n[[{{1x|foo././bar}}]]\n[[{{1x|foo{bar}}]]\n[[{{1x|foo}bar}}]]\n[[{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}]]", |
| 827 |
"html2html": "<p data-parsoid='{\"dsr\":[0,174,0,0]}'>[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n<span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[61,91,8,9]}'>[[foo~~~bar]]</span>\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo<a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external autonumber\" data-parsoid='{\"dsr\":[149,169,19,1]}'></a>xyz]]</p>\n\n<p data-parsoid='{\"dsr\":[176,400,0,0]}'>[[<span about=\"#mwt7\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[178,193,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"./../foo\"}},\"i\":0}}]}'>./../foo</span>|bar]]\n[[<span about=\"#mwt12\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[202,214,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo/.\"}},\"i\":0}}]}'>foo/.</span>|bar]]\n[[<span about=\"#mwt17\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[223,236,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo/..\"}},\"i\":0}}]}'>foo/..</span>|bar]]\n[[<span about=\"#mwt22\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[245,262,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo~~~~bar\"}},\"i\":0}}]}'>foo~~~~bar</span>]]\n[[<span about=\"#mwt27\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[267,281,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo>bar\"}},\"i\":0}}]}'>foo>bar</span>]]\n[[<span about=\"#mwt32\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[286,303,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo././bar\"}},\"i\":0}}]}'>foo././bar</span>]]\n[[<span about=\"#mwt37\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[308,322,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo{bar\"}},\"i\":0}}]}'>foo{bar</span>]]\n[[<span about=\"#mwt42\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[327,341,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo}bar\"}},\"i\":0}}]}'>foo}bar</span>]]\n[[<span about=\"#mwt47\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[346,360,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo[bar\"}},\"i\":0}}]}'>foo[bar</span>]]\n[[<span about=\"#mwt52\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[365,379,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo]bar\"}},\"i\":0}}]}'>foo]bar</span>]]\n[[<span about=\"#mwt57\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[384,398,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo<bar\"}},\"i\":0}}]}'>foo<bar</span>]]</p>", |
| 828 |
"html2wt": "[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n<nowiki>[[foo~~~bar]]</nowiki>\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n[[{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}|bar]]\n[[{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}]]\n[[{{1x|foo>bar}}]]\n[[{{1x|foo././bar}}]]\n[[{{1x|foo{bar}}]]\n[[{{1x|foo}bar}}]]\n[[{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}]]", |
| 829 |
"selser [2,4,[4,0,0,0,0,0,0,0,0,0,3,0,0,0,2,0,4,0,0,0,0,0,4]]": "qotbd7\n\n[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n124i42d\n\n1kvpep{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}|bar]]\n[[{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}]]\n[[{{1x|foo>bar}}{{1x|foo././bar}}]]\n[[{{1x|foo{bar}}ray2sa]]\n[[{{1x|foo}bar}}6gtjnj{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}1baix6o", |
| 830 |
"selser [0,0,[4,0,0,0,2,0,0,0,3,0,0,0,0,0,4,0,0,0,0,0,0,0,2]]": "[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n1cpfkcv{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}yrz3yc|bar]]\n[[{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}{{1x|foo>bar}}]]\n[[{{1x|foo././bar}}]]\n[[{{1x|foo{bar}}1vcbz01{{1x|foo}bar}}]]\n[[{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}tpybk4]]", |
| 831 |
"selser [2,2,4]": "1cqndhq\n\n[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n1m64qc8\n\n1w5jbhp", |
| 832 |
"selser [2,0,4]": "1miybq4\n\n[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n1v0vumv", |
| 833 |
"selser [0,3,[3,0,0,0,3,0,3,0,0,0,4,0,4,0,4,0,3,0,3,0,0,0,0]]": "[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}{{1x|foo/..}}{{1x|foo~~~~bar}}]]\n[[{{1x|foo>bar}}1369k38{{1x|foo././bar}}1s2pdje{{1x|foo{bar}}kc7br8{{1x|foo}bar}}{{1x|foo[bar}}{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}]]", |
| 834 |
"selser [2,2,2]": "1p7ag6r\n\n[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\nzgbtfl\n\n1s6qnfr\n\n[[{{1x|./../foo}}|bar]]\n[[{{1x|foo/.}}|bar]]\n[[{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}]]\n[[{{1x|foo>bar}}]]\n[[{{1x|foo././bar}}]]\n[[{{1x|foo{bar}}]]\n[[{{1x|foo}bar}}]]\n[[{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}]]", |
| 835 |
"selser [2,0,[0,0,4,0,4,0,0,0,4,0,2,0,2,0,0,0,2,0,0,0,0,0,0]]": "1ys83ti\n\n[[./../foo|bar]]\n[[foo�|bar]]\n[[foo/.|bar]]\n[[foo/..|bar]]\n[[foo~~~bar]]\n[[foo>bar]]\n[[foo[bar]]\n[[.]]\n[[..]]\n[[foo././bar]]\n[[foo[http://example.com]xyz]]\n\n[[{{1x|./../foo}}3vtcxh{{1x|foo/.}}17795w{{1x|foo/..}}|bar]]\n[[{{1x|foo~~~~bar}}nbklz1{{1x|foo>bar}}1jbv0hg]]\n[[{{1x|foo././bar}}zoqgl4]]\n[[{{1x|foo{bar}}]]\n[[{{1x|foo}bar}}nhq2qs]]\n[[{{1x|foo[bar}}]]\n[[{{1x|foo]bar}}]]\n[[{{1x|foo<bar}}]]" |
| 836 |
}, |
| 837 |
"Replacing whitespace with tabs still doesn't break the list (gerrit 78327)": { |
| 838 |
"html2wt": "* a\n* b\n* c\n* d" |
| 839 |
}, |
| 840 |
"Ruby markup (W3C-style)": { |
| 841 |
"html2wt": "; Mono-ruby for individual base characters\n: <ruby>日<rt>に</rt>本<rt>ほん</rt>語<rt>ご</rt></ruby>\n; Group ruby\n: <ruby>今日<rt>きょう</rt></ruby>\n; Jukugo ruby\n: <ruby>法<rb>華</rb><rb>経</rb><rt>ほ</rt><rt>け</rt><rt>きょう</rt></ruby>\n; Inline ruby\n: <ruby>東<rb>京</rb><rp>(</rp><rt>とう</rt><rt>きょう</rt><rp>)</rp></ruby>\n; Double-sided ruby\n: <ruby><rb>旧</rb><rb>金</rb><rb>山</rb><rt>jiù</rt><rt>jīn</rt><rt>shān</rt><rtc>San Francisco</rtc></ruby>\n\n<ruby>\n<rb>♥</rb><rtc><rt>Heart</rt></rtc><rtc lang=\"fr\"><rt>Cœur</rt></rtc>\n<rb>☘</rb><rtc><rt>Shamrock</rt></rtc><rtc lang=\"fr\"><rt>Trèfle</rt></rtc>\n<rb>✶</rb><rtc><rt>Star</rt></rtc><rtc lang=\"fr\"><rt>Étoile</rt></rtc>\n</ruby>\n" |
| 842 |
}, |
| 843 |
"Sanitizer: Validating that <meta> and <link> work, but only for Microdata": { |
| 844 |
"wt2html": "<div itemscope=\"\" data-parsoid='{\"stx\":\"html\",\"dsr\":[0,308,15,6]}'>\n\t<p data-parsoid='{\"dsr\":[17,301,0,0]}'><meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></p>\n</div>", |
| 845 |
"wt2wt": "<div itemscope=\"\">\n\t<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n</div>", |
| 846 |
"html2html": "<div itemscope=\"\" data-parsoid='{\"stx\":\"html\",\"dsr\":[0,244,18,6]}'>\n\t<p data-parsoid='{\"dsr\":[20,236,0,0]}'><meta itemprop=\"hello\" content=\"world\" />\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" content=\"5\" />\n\t<a rel=\"mw:ExtLink nofollow\" href=\"http://example.org\" class=\"external autonumber\" data-parsoid='{\"dsr\":[143,163,19,1]}'></a>\n\t<link rel=\"stylesheet\" href=\"http://example.org\">\n\t<a rel=\"mw:ExtLink nofollow\" href=\"http://example.org\" class=\"external autonumber\" data-parsoid='{\"dsr\":[216,236,19,1]}'></a></p>\n\n</div>", |
| 847 |
"html2wt": "<div itemscope=\"\">\n\t<meta itemprop=\"hello\" content=\"world\" />\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" content=\"5\" />\n\t[http://example.org]\n\t<link rel=\"stylesheet\" href=\"http://example.org\">\n\t[http://example.org]\n\n</div>", |
| 848 |
"selser [[0,1,4]]": "<div itemscope>\n\t<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\n1uvppgm</div>", |
| 849 |
"selser [[2,0,2]]": "<div itemscope>9oayah\n\t<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n\n18xd70d\n</div>", |
| 850 |
"selser [2]": "gokl50<div itemscope>\n\t<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n</div>", |
| 851 |
"selser [[0,[2],2]]": "<div itemscope>\n\t1uu4540<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\n1rud2ro\n</div>", |
| 852 |
"selser [[4,1,0]]": "<div itemscope>ayn37o\n<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n</div>", |
| 853 |
"selser [[4,[3],0]]": "<div itemscope>jjbnc0\n</div>", |
| 854 |
"selser [[0,0,4]]": "<div itemscope>\n\t<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n\n51og3w</div>", |
| 855 |
"selser [[0,[4],3]]": "<div itemscope>\n\t1rj6y53\n</div>", |
| 856 |
"selser [[0,3,4]]": "<div itemscope>\n\t1dsojdk</div>", |
| 857 |
"selser [[2,1,0]]": "<div itemscope>obr3o0\n\t<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n</div>", |
| 858 |
"selser [[0,1,0]]": "<div itemscope>\n\t<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n</div>", |
| 859 |
"selser [[0,[2],0]]": "<div itemscope>\n\t7gwr4j<nowiki><meta itemprop=\"hello\" content=\"world\"></nowiki>\n\t<nowiki><meta http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\"></nowiki>\n\t<nowiki><link itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" href=\"{{SERVER}}\"></nowiki>\n\t<nowiki><link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\"></nowiki>\n</div>", |
| 860 |
"selser [[3,2,0]]": "<div itemscope>1mh1xk5\n<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n</div>", |
| 861 |
"selser [1]": "<div itemscope=\"\" data-foobar=\"itggi0\">\n\t<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n</div>", |
| 862 |
"selser [[2,2,0]]": "<div itemscope>59jrda\n\t131zru6\n<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n</div>", |
| 863 |
"selser [[2,4,0]]": "<div itemscope>1k21p46\n\t10tbl0m\n</div>", |
| 864 |
"selser [[3,0,4]]": "<div itemscope>\n<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n14z0d3m</div>", |
| 865 |
"selser [[0,2,0]]": "<div itemscope>\n\tcfkjjt\n<meta itemprop=\"hello\" content=\"world\">\n\t<meta http-equiv=\"refresh\" content=\"5\">\n\t<meta itemprop=\"hello\" http-equiv=\"refresh\" content=\"5\">\n\t<link itemprop=\"hello\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" href=\"{{SERVER}}\">\n\t<link rel=\"stylesheet\" itemprop=\"hello\" href=\"{{SERVER}}\">\n</div>" |
| 866 |
}, |
| 867 |
"Say the magic word": { |
| 868 |
"html2wt": "* {{PAGENAME}}\n* {{PAGENAMEE}}\n* {{FULLPAGENAME}}\n* {{FULLPAGENAMEE}}\n* {{BASEPAGENAME}}\n* {{BASEPAGENAMEE}}\n* {{SUBPAGENAME}}\n* {{SUBPAGENAMEE}}\n* {{ROOTPAGENAME}}\n* {{ROOTPAGENAMEE}}\n* {{TALKPAGENAME}}\n* {{TALKPAGENAMEE}}\n* {{SUBJECTPAGENAME}}\n* {{SUBJECTPAGENAMEE}}\n* {{NAMESPACEE}}\n* {{NAMESPACE}}\n* {{NAMESPACENUMBER}}\n* {{TALKSPACE}}\n* {{TALKSPACEE}}\n* {{SUBJECTSPACE}}\n* {{SUBJECTSPACEE}}\n* {{Dynamic|{{NUMBEROFUSERS}}|{{NUMBEROFPAGES}}|{{CURRENTVERSION}}|{{CONTENTLANGUAGE}}|{{DIRECTIONMARK}}|{{CURRENTTIMESTAMP}}|{{NUMBEROFARTICLES}}}}" |
| 869 |
}, |
| 870 |
"Self closed html pairs (T7487)": { |
| 871 |
"wt2html": "<center data-parsoid='{\"stx\":\"html\",\"dsr\":[0,47,8,9]}'><font id=\"bug\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[8,25,17,0]}'></font>Centered text</center>\n<div data-parsoid='{\"stx\":\"html\",\"dsr\":[48,88,5,6]}'><font id=\"bug2\" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[53,71,18,0]}'></font>In div text</div>", |
| 872 |
"html2wt": "<center><font id=\"bug\">Centered text</font></center><font id=\"bug\"><div><font id=\"bug2\">In div text</font></div></font>" |
| 873 |
}, |
| 874 |
"Self-closed noinclude, includeonly, onlyinclude tags": { |
| 875 |
"wt2html": "<meta typeof=\"mw:Includes/NoInclude\" data-parsoid='{\"src\":\"<noinclude />\",\"dsr\":[0,13,null,null]}'/>\n<meta typeof=\"mw:Includes/IncludeOnly\" data-parsoid='{\"dsr\":[14,29,null,null]}' data-mw='{\"src\":\"<includeonly />\"}'/>\n<meta typeof=\"mw:Includes/OnlyInclude\" data-parsoid='{\"src\":\"<onlyinclude />\",\"dsr\":[30,45,null,null]}'/>", |
| 876 |
"html2html": "\n\n", |
| 877 |
"html2wt": "\n\n" |
| 878 |
}, |
| 879 |
"Self-closed tag with broken attribute value quoting": { |
| 880 |
"wt2html": "<div title=\"Hello world \" data-parsoid='{\"stx\":\"html\",\"selfClose\":true,\"dsr\":[0,26,26,0]}'></div><p data-parsoid='{\"dsr\":[26,29,0,0]}'>Foo</p>" |
| 881 |
}, |
| 882 |
"Simple list": { |
| 883 |
"html2wt": "* Item 1\n* Item 2" |
| 884 |
}, |
| 885 |
"Simple template": { |
| 886 |
"html2wt": "This is a test template\n" |
| 887 |
}, |
| 888 |
"Single-comment whitespace lines dont break lists, and neither do multi-comment whitespace lines": { |
| 889 |
"html2wt": "* a\n* b\n* c\n* d" |
| 890 |
}, |
| 891 |
"Single-line or multiline-comments can follow headings": { |
| 892 |
"selser [2,4,3,1,0,4,[2],3]": "1is6xi5\n\n==foo==\n1c6vh2i\n\n==bar==<!--c1-->\nvp2olc\n\n==xmkpambaz==<!--\nc2\nc3-->" |
| 893 |
}, |
| 894 |
"Spaced heading with element": { |
| 895 |
"selser [[3,4,0]]": "=== 1z3xsf hi ho ===", |
| 896 |
"selser [[2,0,0]]": "=== 170gdm3hi <span id=\"x\">hi</span> hi ho ===", |
| 897 |
"selser [1]": "=== hi <span id=\"x\">hi</span> hi ho ===", |
| 898 |
"selser [2]": "y61ost\n\n=== hi <span id=\"x\">hi</span> hi ho ===", |
| 899 |
"selser [[0,3,0]]": "=== hi hi ho ===", |
| 900 |
"selser [[4,[2],0]]": "=== 3r47fx<span id=\"x\">13z345whi</span> hi ho ===", |
| 901 |
"selser [[3,4,3]]": "=== 7t8v47 ===", |
| 902 |
"selser [[3,0,0]]": "=== <span id=\"x\">hi</span> hi ho ===", |
| 903 |
"selser [[0,1,2]]": "=== hi <span id=\"x\" data-foobar=\"1f91hhe\">hi</span>r9yx8e hi ho ===", |
| 904 |
"selser [[0,3,4]]": "=== hi 1wfz4el ===", |
| 905 |
"selser [[0,1,0]]": "=== hi <span id=\"x\" data-foobar=\"bwaljq\">hi</span> hi ho ===", |
| 906 |
"selser [[4,3,0]]": "=== 1r0v4o9 hi ho ===", |
| 907 |
"selser [[0,[2],0]]": "=== hi <span id=\"x\">1icvnnlhi</span> hi ho ===", |
| 908 |
"selser [[3,0,4]]": "=== <span id=\"x\">hi</span>12czxl1 ===", |
| 909 |
"selser [[0,2,2]]": "=== hi 15wkygl<span id=\"x\">hi</span>vzqtm7 hi ho ===", |
| 910 |
"selser [[3,0,3]]": "=== <span id=\"x\">hi</span> ===", |
| 911 |
"selser [[0,0,2]]": "=== hi <span id=\"x\">hi</span>1w2au0v hi ho ===", |
| 912 |
"selser [[4,[3],0]]": "=== 64yg7h<span id=\"x\"></span> hi ho ===" |
| 913 |
}, |
| 914 |
"Special page link with fragment": { |
| 915 |
"metadata": "" |
| 916 |
}, |
| 917 |
"Special parser function": { |
| 918 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,65,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,23,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:RandomPage\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span>\n<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[24,45,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:BaDtItLe\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span>\n<span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[46,65,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:Foobar\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span></p>", |
| 919 |
"html2html": "<p data-parsoid='{\"dsr\":[0,65,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,23,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:RandomPage\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span>\n<span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[24,45,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:BaDtItLe\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span>\n<span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[46,65,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:Foobar\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span></p>" |
| 920 |
}, |
| 921 |
"Strip marker in formatNum": { |
| 922 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,53,0,0]}'><span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,25,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"formatnum:1<nowiki/>2\",\"function\":\"formatnum\"},\"params\":{},\"i\":0}}]}'>12</span>\n<span about=\"#mwt4\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[26,53,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"formatnum:1<nowiki/>2\",\"function\":\"formatnum\"},\"params\":{\"1\":{\"wt\":\"R\"}},\"i\":0}}]}'>12</span></p>", |
| 923 |
"html2html": "<p data-parsoid='{\"dsr\":[0,53,0,0]}'><span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,25,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"formatnum:1<nowiki/>2\",\"function\":\"formatnum\"},\"params\":{},\"i\":0}}]}'>12</span> <span about=\"#mwt4\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[26,53,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"formatnum:1<nowiki/>2\",\"function\":\"formatnum\"},\"params\":{\"1\":{\"wt\":\"R\"}},\"i\":0}}]}'>12</span></p>", |
| 924 |
"html2wt": "{{formatnum:1<nowiki/>2}} {{formatnum:1<nowiki/>2|R}}" |
| 925 |
}, |
| 926 |
"Strip marker in padleft": { |
| 927 |
"html2wt": "xy\n" |
| 928 |
}, |
| 929 |
"Strip marker in padright": { |
| 930 |
"html2wt": "xy\n" |
| 931 |
}, |
| 932 |
"Subpage noslash link": { |
| 933 |
"html2wt": "[[Subpage test/subpage|subpage]]\n" |
| 934 |
}, |
| 935 |
"T10293: Use of center tag ruins paragraph formatting": { |
| 936 |
"html2wt": "<center>\nfoo\n\n</center>\nbar\n\n baz\n" |
| 937 |
}, |
| 938 |
"T17491: <ins>/<del> in blockquote": { |
| 939 |
"html2wt": "<blockquote>\nFoo <del>bar</del> <ins>baz</ins> quux\n\n</blockquote>" |
| 940 |
}, |
| 941 |
"T192913 Regression test: 2. html2wt of links should not trip on parser functions found in target (2)": { |
| 942 |
"wt2wt": "[[Category:Bugs-{{#if:blah|Regression|None}}|<nowiki>Category:Bugs-{{#if:blah|Regression|None}}</nowiki>]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|<nowiki>Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}</nowiki>]]", |
| 943 |
"html2html": "<link typeof=\"mw:ExpandedAttrs\" about=\"#mwt2\" rel=\"mw:PageProp/Category\" href=\"./Category:Bugs-Regression\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Category:Bugs-Regression\"},\"sa\":{\"href\":\"Category:Bugs-{{#if:blah|Regression|None}}\"},\"dsr\":[0,46,null,null]}' data-mw='{\"attribs\":[[{\"txt\":\"href\"},{\"html\":\"Category:Bugs-<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"},{\\\"k\\\":\\\"2\\\"}]],\\\"dsr\\\":[16,44,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"#if:blah\\\",\\\"function\\\":\\\"if\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"Regression\\\"},\\\"2\\\":{\\\"wt\\\":\\\"None\\\"}},\\\"i\\\":0}}]}'>Regression</span>\"}]]}'/>\n<link typeof=\"mw:ExpandedAttrs\" about=\"#mwt5\" rel=\"mw:PageProp/Category\" href=\"./Category:Bugs-Regression-2020\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Category:Bugs-Regression-2020\"},\"sa\":{\"href\":\"Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}\"},\"dsr\":[47,116,null,null]}' data-mw='{\"attribs\":[[{\"txt\":\"href\"},{\"html\":\"Category:Bugs-<span about=\\\"#mwt3\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"},{\\\"k\\\":\\\"2\\\"}]],\\\"dsr\\\":[63,91,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"#if:blah\\\",\\\"function\\\":\\\"if\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"Regression\\\"},\\\"2\\\":{\\\"wt\\\":\\\"None\\\"}},\\\"i\\\":0}}]}'>Regression</span>-<span about=\\\"#mwt4\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"},{\\\"k\\\":\\\"2\\\"}]],\\\"dsr\\\":[92,114,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"#if:blah\\\",\\\"function\\\":\\\"if\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"2020\\\"},\\\"2\\\":{\\\"wt\\\":\\\"None\\\"}},\\\"i\\\":0}}]}'>2020</span>\"}]]}'/>", |
| 944 |
"html2wt": "[[Category:Bugs-{{#if:blah|Regression|None}}]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}]]", |
| 945 |
"selser [2,0,0]": "fzlv20\n[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 946 |
"selser [3,0,0]": "\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 947 |
"selser [1,0,2]": "[[Category:Bugs-{{#if:blah|Regression|None}}|<nowiki>Category:Bugs-{{#if:blah|Regression|None}}</nowiki>]]\nch5480\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 948 |
"selser [4,2,1]": "1qzsk51\n\n1q7u882\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}]]", |
| 949 |
"selser [3,0,2]": "\n1z0mf5c\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 950 |
"selser [0,0,1]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|<nowiki>Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}</nowiki>]]", |
| 951 |
"selser [0,3,4]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n1cdxgr", |
| 952 |
"selser [3,2,1]": "e3d6n4\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}]]", |
| 953 |
"selser [0,0,4]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\nq4i7jz", |
| 954 |
"selser [2,0,2]": "gp679p\n[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n2zkhkj\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 955 |
"selser [1,0,0]": "[[Category:Bugs-{{#if:blah|Regression|None}}|<nowiki>Category:Bugs-{{#if:blah|Regression|None}}</nowiki>]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 956 |
"selser [0,3,2]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\nf3tw5x\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 957 |
"selser [0,4,0]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n11dapge\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 958 |
"selser [0,3,0]": "[[Category:Bugs-{{#if:blah|Regression|None}}|fragment]]\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 959 |
"selser [4,2,0]": "77wx48\n\n1dy0ips\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 960 |
"selser [3,2,0]": "1kxc4ot\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]", |
| 961 |
"selser [4,2,2]": "1c1qznt\n\nklxc2j\n\n1ixrma7\n[[Category:Bugs-{{#if:blah|Regression|None}}-{{#if:blah|2020|None}}|fragment]]" |
| 962 |
}, |
| 963 |
"T21052 U+3000 IDEOGRAPHIC SPACE should terminate bracketed external links": { |
| 964 |
"wt2wt": "[http://www.example.org/ ideograms]", |
| 965 |
"html2wt": "[http://www.example.org/ ideograms]\n", |
| 966 |
"selser [2]": "1dbyq81\n\n[http://www.example.org/ ideograms]", |
| 967 |
"selser [[2]]": "k7rfsq[http://www.example.org/ ideograms]", |
| 968 |
"selser [1]": "[http://www.example.org/ ideograms]" |
| 969 |
}, |
| 970 |
"T2523: Template shouldn't eat newline (or add an extra one before table)": { |
| 971 |
"html2wt": "foo\n\n{|\n|1\n|2\n|-\n|3\n|4\n|}" |
| 972 |
}, |
| 973 |
"T2529: Uncovered bullet": { |
| 974 |
"wt2wt": "*Foo{{bullet}}\n", |
| 975 |
"html2wt": "* Foo{{bullet}}\n", |
| 976 |
"selser [2]": "xpt49k\n*Foo {{bullet}}", |
| 977 |
"selser [[2,0,0]]": "* b9vx2l\n*Foo {{bullet}}", |
| 978 |
"selser [1]": "*Foo {{bullet}}", |
| 979 |
"selser [[1,0,0]]": "*Foo {{bullet}}" |
| 980 |
}, |
| 981 |
"T2529: Uncovered bullet in a deeply nested list": { |
| 982 |
"wt2wt": "*******Foo\n{{bullet}}\n", |
| 983 |
"html2html": "<ul data-parsoid='{\"dsr\":[0,22,0,0]}'><li data-parsoid='{\"dsr\":[0,11,1,0]}'><ul data-parsoid='{\"dsr\":[1,11,0,0]}'><li data-parsoid='{\"dsr\":[1,11,1,0]}'><ul data-parsoid='{\"dsr\":[2,11,0,0]}'><li data-parsoid='{\"dsr\":[2,11,1,0]}'><ul data-parsoid='{\"dsr\":[3,11,0,0]}'><li data-parsoid='{\"dsr\":[3,11,1,0]}'><ul data-parsoid='{\"dsr\":[4,11,0,0]}'><li data-parsoid='{\"dsr\":[4,11,1,0]}'><ul data-parsoid='{\"dsr\":[5,11,0,0]}'><li data-parsoid='{\"dsr\":[5,11,1,0]}'><ul data-parsoid='{\"dsr\":[6,11,0,0]}'><li data-parsoid='{\"dsr\":[6,11,1,0,1,0]}'>Foo</li></ul></li></ul></li></ul></li></ul></li></ul></li></ul></li>\n<li about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[12,22,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"bullet\",\"href\":\"./Template:Bullet\"},\"params\":{},\"i\":0}}]}'>Bar</li></ul>\n", |
| 984 |
"html2wt": "******* Foo\n{{bullet}}\n", |
| 985 |
"selser [[[[[2]]],0,0]]": "**1pu16hr\n*******Foo {{bullet}}", |
| 986 |
"selser [[[[2]],0,0]]": "** vaurd6\n*******Foo {{bullet}}", |
| 987 |
"selser [[2,0,0]]": "* oag6qw\n*******Foo {{bullet}}", |
| 988 |
"selser [1]": "*******Foo {{bullet}}", |
| 989 |
"selser [[[1],0,0]]": "*******Foo {{bullet}}", |
| 990 |
"selser [2]": "113swo7\n*******Foo {{bullet}}", |
| 991 |
"selser [[[[1]],0,0]]": "*******Foo {{bullet}}", |
| 992 |
"selser [[[2],0,0]]": "*lrgux8\n*******Foo {{bullet}}", |
| 993 |
"selser [[1,0,0]]": "*******Foo {{bullet}}", |
| 994 |
"selser [[[[[[[1]]]]],0,0]]": "*******Foo {{bullet}}" |
| 995 |
}, |
| 996 |
"T2553: link with two variables in a piped link": { |
| 997 |
"wt2wt": "{|\n|[[{{{1}}}<nowiki>|</nowiki>{{{2}}}]]\n|}", |
| 998 |
"html2html": "<table data-parsoid='{\"dsr\":[0,43,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[3,41,0,0]}'><tr data-parsoid='{\"autoInsertedStart\":true,\"dsr\":[3,40,0,0]}'><td data-parsoid='{\"dsr\":[3,40,1,0]}'>[[<span about=\"#mwt11\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[]],\"dsr\":[6,13,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"1\"},\"params\":{},\"i\":0}}]}'>{{{1}}}</span><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[13,31,8,9]}'>|</span><span about=\"#mwt12\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[]],\"dsr\":[31,38,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"2\"},\"params\":{},\"i\":0}}]}'>{{{2}}}</span>]]</td></tr>\n</tbody></table>", |
| 999 |
"html2wt": "{|\n|[[{{{1}}}<nowiki>|</nowiki>{{{2}}}]]\n|}", |
| 1000 |
"selser [1]": "{| data-foobar=\"bouvs0\"\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1001 |
"selser [[3,2]]": "{|<!--yuc62n-->\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1002 |
"selser [[0,2]]": "{|\n<!--bfvyi1-->|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1003 |
"selser [[0,1]]": "{|\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1004 |
"selser [[4,[[[2,0,0,0,0]],0]]]": "{|<!--1531c7v-->\n|gzam8[[{{{1}}}|{{{2}}}]]\n|}", |
| 1005 |
"selser [2]": "oxk5cd\n{|\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1006 |
"selser [[3,[[[2,0,0,0,3]],0]]]": "{|\n|1q9cnf3[[{{{1}}}|{{{2}}}\n|}", |
| 1007 |
"selser [[0,[1,0]]]": "{|\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1008 |
"selser [[3,1]]": "{|\n|[[{{{1}}}|{{{2}}}]]\n|}", |
| 1009 |
"selser [[4,1]]": "{|<!--1t4r17j-->\n|[[{{{1}}}|{{{2}}}]]\n|}" |
| 1010 |
}, |
| 1011 |
"T33490 Turkish: lcfirst 'BLAH'": { |
| 1012 |
"html2wt": "bLAH\n" |
| 1013 |
}, |
| 1014 |
"T33490 Turkish: ucfirst 'blah'": { |
| 1015 |
"html2wt": "Blah\n" |
| 1016 |
}, |
| 1017 |
"T33490 Turkish: ucfirst 'ix'": { |
| 1018 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,14,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,14,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"ucfirst:ix\",\"function\":\"ucfirst\"},\"params\":{},\"i\":0}}]}'>Ix</span></p>", |
| 1019 |
"html2wt": "İx\n" |
| 1020 |
}, |
| 1021 |
"T368721: Closing block tags not on the stack of open elements in lists": { |
| 1022 |
"wt2wt": "<!-- block tag -->*a\nb\n\n<!-- wikitext block tag -->\n*a</p>b", |
| 1023 |
"html2wt": "<!-- block tag -->* a\n\nb\n\n<!-- wikitext block tag -->\n* a</p>b", |
| 1024 |
"selser [0,0,[3],2,0,0,3,2,2,0]": "<!-- block tag -->\n\n1b4e4vd\n\nb\n\n<!-- wikitext block tag -->hn72cb\n*a\noca1l6</p>b", |
| 1025 |
"selser [2,4,0,0,0,2,3,4,0,1]": "1ybhvfi<!-- block tag -->\n\ntokbz0\n*a</div>b\n\nqct18g<!-- wikitext block tag -->1iwxw4e</p>b", |
| 1026 |
"selser [4,2,2,0,4,0,3,[[2]],4,2]": "1xo50fp\n\n129p8fo\n\n1vqct6g\n*a</div>b\n\nixwclk<!-- wikitext block tag -->\n*1guiuega\n18aaumk\n\n1w8jy7v\n\nb", |
| 1027 |
"selser [3,3,0,0,0,4,2,2,0,0]": "*a</div>b\n\npnk6t0\n\n1rcdjnf\n\n1aepdtw\n*a</p>b", |
| 1028 |
"selser [0,0,0,3,4,0,3,[4],0,[4]]": "<!-- block tag -->\n*a\n1ndvsac<!-- wikitext block tag -->\n* 1zt634</p>1ptjkg7", |
| 1029 |
"selser [0,0,[[4]],0,2,0,3,4,3,1]": "<!-- block tag -->\n*1ql13mb\nb\n\nb8fbp1\n\n<!-- wikitext block tag -->1y3uau4\n\nb" |
| 1030 |
}, |
| 1031 |
"T4095: link with pipe and three closing brackets, version 2": { |
| 1032 |
"wt2wt": "[[Main Page|<nowiki>[http://example.com/]</nowiki>]]", |
| 1033 |
"html2html": "<p data-parsoid='{\"dsr\":[0,52,0,0]}'><a rel=\"mw:WikiLink\" href=\"./Main_Page\" title=\"Main Page\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./Main_Page\"},\"sa\":{\"href\":\"Main Page\"},\"dsr\":[0,52,12,2]}'><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[12,50,8,9]}'>[http://example.com/]</span></a></p>", |
| 1034 |
"html2wt": "[[Main Page|<nowiki>[http://example.com/]</nowiki>]]", |
| 1035 |
"selser [1]": "[[Main Page|[http://example.com/]]]", |
| 1036 |
"selser [2]": "fzyteq\n\n[[Main Page|[http://example.com/]]]", |
| 1037 |
"selser [[2]]": "v7jqm7[[Main Page|[http://example.com/]]]" |
| 1038 |
}, |
| 1039 |
"T45661: Piped links with identical prefixes": { |
| 1040 |
"html2wt": "[[Prefixed article|prefixed articles with spaces]]\n\n[[Prefixed article|prefixed articlesaoeu]]\n\n[[Main Page|Main Page test]]\n", |
| 1041 |
"selser [0,2,[[3]],2,[2]]": "[[prefixed article|prefixed articles with spaces]]\n\n7u53g5\n\n1fq2srm\n\n106il2l[[Main Page|Main Page test]]" |
| 1042 |
}, |
| 1043 |
"T4702: Mismatched <i>, <b> and <a> tags are invalid": { |
| 1044 |
"wt2wt": "''[http://example.com text]''\n[http://example.com '''text''']\n''Something [http://example.com in italic]''\n''Something [http://example.com mixed''''', even bold''''']'''\n'''''Now [http://example.com both]'''''", |
| 1045 |
"html2html": "<p data-parsoid='{\"dsr\":[0,209,0,0]}'><i data-parsoid='{\"dsr\":[0,29,2,2]}'><a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external text\" data-parsoid='{\"dsr\":[2,27,20,1]}'>text</a></i>\n<a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external text\" data-parsoid='{\"dsr\":[30,61,20,1]}'><b data-parsoid='{\"dsr\":[50,60,3,3]}'>text</b></a>\n<i data-parsoid='{\"dsr\":[62,106,2,2]}'>Something <a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external text\" data-parsoid='{\"dsr\":[74,104,20,1]}'>in italic</a></i>\n<i data-parsoid='{\"dsr\":[107,169,2,2]}'>Something <a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external text\" data-parsoid='{\"dsr\":[119,166,20,1]}'>mixed<i data-parsoid='{\"dsr\":[144,165,2,2]}'><b data-parsoid='{\"dsr\":[146,163,3,3]}'>, even bold</b></i></a>'</i>\n<i data-parsoid='{\"dsr\":[170,209,2,2]}'><b data-parsoid='{\"dsr\":[172,207,3,3]}'>Now <a rel=\"mw:ExtLink nofollow\" href=\"http://example.com\" class=\"external text\" data-parsoid='{\"dsr\":[179,204,20,1]}'>both</a></b></i></p>", |
| 1046 |
"html2wt": "''[http://example.com text]''\n[http://example.com '''text''']\n''Something [http://example.com in italic]''\n''Something [http://example.com mixed''''', even bold''''']'''\n'''''Now [http://example.com both]'''''", |
| 1047 |
"selser [[[3],0,0,0,0,[0,[3,1]],0,[4,3,2],0,3]]": "\n[http://example.com '''text]'''\n''Something [http://example.com]''\n''ujxjzra47q9r'''\n", |
| 1048 |
"selser [2]": "1w5nzr6\n\n''[http://example.com text'']\n[http://example.com '''text]'''\n''Something [http://example.com in italic'']\n''Something [http://example.com mixed''''', even bold]'''\n'''''Now [http://example.com both''''']", |
| 1049 |
"selser [1]": "''[http://example.com text'']\n[http://example.com '''text]'''\n''Something [http://example.com in italic'']\n''Something [http://example.com mixed''''', even bold]'''\n'''''Now [http://example.com both''''']", |
| 1050 |
"selser [[[[2,0]],3,[[2]],1,4,[0,3],0,[0,4,4],4,1]]": "''[http://example.com 1ie384ttext'']''[http://example.com '''k7725ktext''']1dy3095''Something ''\n''Something 1spdymo1y4ijr9''1cethmn'''''Now [http://example.com both''''']'''", |
| 1051 |
"selser [[4,0,4,2,0,1,0,3,0,2]]": "grwjkq\n1lot087vcvcyx'''\n''Something [http://example.com in italic'']''\n\n1m0k7zr'''''Now [http://example.com both''''']", |
| 1052 |
"selser [[4,0,[2],3,3,1,2,3,0,[[0,[3,0]]]]]": "1om7u04\n[http://example.com vrwdsq'''text]''Something [http://example.com in italic'']''wm0zay\n\n'''''Now [http://example.com ''''']'''''", |
| 1053 |
"selser [[[[2,0]],3,[[2]],3,0,4,4,3,0,2]]": "''[http://example.com uz3hfhtext'']''[http://example.com '''w3pgfntext''']\n1apcmhc1asm4e3\n1b2pppj'''''Now [http://example.com both''''']", |
| 1054 |
"selser [[2,0,[[2]],0,0,3,0,2,0,[[0,2]]]]": "1mmp26e''[http://example.com text'']\n[http://example.com '''12agtubtext''']'''\n\n1fumkj3''Something [http://example.com mixed''''', even bold]'''\n'''''Now 7tlb0a[http://example.com both''''']'''''", |
| 1055 |
"selser [[0,0,[2],1,3,[4,[3,0]],4,[0,[3,4],2],0,[1]]]": "''[http://example.com text'']\n[http://example.com 9mtm57'''text]''bc87qa[http://example.com '']''dddk6d''Something [http://example.com wrlh1r]1nyzqa'<nowiki/>''\n'''''Now [http://example.com both''''']'''''", |
| 1056 |
"selser [[[[2,4]],3,[1],0,4,[0,[0,1]],3,2,0,[3]]]": "''[http://example.com gmrlyetextytqaz0]''[http://example.com '''text''']'''1ms01p0''Something [http://example.com in italic]''py6uhu''Something [http://example.com mixed''''', even bold]'''\n", |
| 1057 |
"selser [[[3],3,[3],1,4,[3,2],0,[0,[0,2],4],0,[4]]]": "[http://example.com]248wls''1e6rzwq[http://example.com in italic'']''\n''Something [http://example.com mixed1m8avn6''''', even bold]1yvo8ai''\n'''hr40qt'''", |
| 1058 |
"selser [[[[0,2]],2,[4],2,0,[4,[3,2]],3,[0,[0,3],0],0,[4]]]": "''[http://example.com text1p6xyxz'']''1hx28uc\n[http://example.com 14ob795]1epk0re'''\n''1vvap2n[http://example.com eov9sf'']Something [http://example.com mixed]'''\n'''ugv2mv'''", |
| 1059 |
"selser [[1,2,2,0,2,[4,[0,4]],0,[0,[0,[[3]]],0],0,2]]": "''[http://example.com text'']''11n11i3\n8k2sbo[http://example.com '''text]'''kilfpv\n''1ga484n[http://example.com in italic1jyu5cf]''\n''Something [http://example.com mixed]'''\ngcoz8y'''''Now [http://example.com both''''']", |
| 1060 |
"selser [[[1],0,[4],0,0,[0,4],4,[0,1,3],3,[[4,3]]]]": "''[http://example.com text'']''\n[http://example.com 3dopwh]'''\n''Something 1ob2p5f''ojb293''Something [http://example.com mixed''''', even bold]'''987qp0'''''", |
| 1061 |
"selser [[[3],0,1,0,0,[2,[3,0]],3,[3,2,4],2,[2]]]": "\n[http://example.com '''text]'''\n''1xjshhaSomething [http://example.com '']1wmn059[http://example.com mixed''''', even bold]x2ogu4''1iok13m\n'''hc7hv6''Now [http://example.com both''''']'''", |
| 1062 |
"selser [[4,2,3,2,3,[4,0],0,[0,2,0],0,0]]": "iivdyk17hf24y\n14qclac'''''13xl0an[http://example.com in italic'']''\n''Something 1gcs6ue[http://example.com mixed''''', even bold]'''\n'''''Now [http://example.com both''''']", |
| 1063 |
"selser [[4,0,[3],4,0,4,2,3,0,2]]": "mire6j\n[http://example.com]alv1v8\nahtp4ipkxdyg\n\n1h9vu0l'''''Now [http://example.com both''''']" |
| 1064 |
}, |
| 1065 |
"T53086: Double newlines in blockquotes should be turned into paragraphs": { |
| 1066 |
"html2wt": "<blockquote>\nFoo\n\nBar\n\n</blockquote>" |
| 1067 |
}, |
| 1068 |
"T73074: More fostering fun": { |
| 1069 |
"wt2wt": "[[Category:Two]]\n<table><td></td></tr>{{1x|<tr>}}<!--c-->", |
| 1070 |
"html2wt": "[[Category:Two]]\n<table><td></td></tr>{{1x|<tr>}}<!--c-->", |
| 1071 |
"selser [0,4]": "\nlomg0q", |
| 1072 |
"selser [0,1]": "<table data-foobar=\"9cf581\"><td></td>{{1x|<tr>}}<!--c-->[[Category:Two]]", |
| 1073 |
"selser [2,[[[3],0,0]]]": "61fo7n\n<table>{{1x|<tr>}}<!--c-->", |
| 1074 |
"selser [3,1]": "<table data-foobar=\"nvceso\"><td></td>{{1x|<tr>}}<!--c-->[[Category:Two]]", |
| 1075 |
"selser [2,[4]]": "lmrcpt\n<table><!--tdercx-->", |
| 1076 |
"selser [2,4]": "qee0jt\n\nw6btke", |
| 1077 |
"selser [1,[2]]": "[[Category:Two]]<table><!--r9jimg--><td></td>{{1x|<tr>}}<!--c-->[[Category:Two]]", |
| 1078 |
"selser [0,[1]]": "<table><td></td>{{1x|<tr>}}<!--c-->", |
| 1079 |
"selser [0,2]": "\n11oow1i<table><td></td>{{1x|<tr>}}<!--c-->[[Category:Two]]", |
| 1080 |
"selser [3,[1]]": "<table><td></td>{{1x|<tr>}}<!--c-->", |
| 1081 |
"selser [0,3]": "", |
| 1082 |
"selser [2,1]": "1mv3j75\n<table data-foobar=\"xgfqp4\"><td></td>{{1x|<tr>}}<!--c-->[[Category:Two]]", |
| 1083 |
"selser [0,[[[4],0,0]]]": "<table><td>1yx3do</td>{{1x|<tr>}}<!--c-->", |
| 1084 |
"selser [3,[[[2],0,0]]]": "<table><td>bu3ntq</td><td></td>{{1x|<tr>}}<!--c-->", |
| 1085 |
"selser [0,[[[3],0,0]]]": "<table>{{1x|<tr>}}<!--c-->" |
| 1086 |
}, |
| 1087 |
"T7678: Double-parsed template argument": { |
| 1088 |
"html2wt": "<nowiki>{{{1}}}</nowiki>\n" |
| 1089 |
}, |
| 1090 |
"T7918: autonumbering": { |
| 1091 |
"selser [4,0,[3],4,3,2,[3],0,0]": "i81tua\n\n\n3o2wz7\n\nrh4a4n\n\nmailto:[email protected]" |
| 1092 |
}, |
| 1093 |
"T8200: blockquotes and paragraph formatting": { |
| 1094 |
"html2wt": "<blockquote>\nfoo\n\n</blockquote>\nbar\n\n baz\n" |
| 1095 |
}, |
| 1096 |
"T8200: paragraphs inside blockquotes (extra line break on close)": { |
| 1097 |
"html2wt": "<blockquote>Line one\n\nLine two\n\n</blockquote>" |
| 1098 |
}, |
| 1099 |
"T8200: paragraphs inside blockquotes (extra line break on open and close)": { |
| 1100 |
"html2wt": "<blockquote>\nLine one\n\nLine two\n\n</blockquote>" |
| 1101 |
}, |
| 1102 |
"T8200: paragraphs inside blockquotes (extra line break on open)": { |
| 1103 |
"selser [[0,[3],2]]": "<blockquote>\n\n1x8wibb\n\n\n\nLine two</blockquote>" |
| 1104 |
}, |
| 1105 |
"T8200: paragraphs inside blockquotes (no extra line breaks)": { |
| 1106 |
"html2wt": "<blockquote>Line one\nLine two</blockquote>" |
| 1107 |
}, |
| 1108 |
"T8563: Section extraction for section shown by <includeonly>": { |
| 1109 |
"wt2html": "<meta typeof=\"mw:Includes/IncludeOnly\" data-parsoid='{\"dsr\":[0,52,null,null]}' data-mw='{\"src\":\"<includeonly>\\n==Includeonly section==\\n</includeonly>\"}'/><meta typeof=\"mw:Includes/IncludeOnly/End\" data-parsoid='{\"src\":\"\",\"dsr\":[52,52,null,null]}'/>\n<h2 id=\"Section_T-2\" data-parsoid='{\"dsr\":[53,68,2,2]}'>Section T-2</h2>", |
| 1110 |
"html2html": "<p data-parsoid='{\"dsr\":[0,32,0,0]}'><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[0,32,8,9]}'>==Section T-2==</span></p>", |
| 1111 |
"html2wt": "<nowiki>==Section T-2==</nowiki>" |
| 1112 |
}, |
| 1113 |
"T8563: Section extraction for section suppressed by <includeonly>": { |
| 1114 |
"wt2html": "<meta typeof=\"mw:Includes/IncludeOnly\" data-parsoid='{\"dsr\":[0,52,null,null]}' data-mw='{\"src\":\"<includeonly>\\n==Includeonly section==\\n</includeonly>\"}'/><meta typeof=\"mw:Includes/IncludeOnly/End\" data-parsoid='{\"src\":\"\",\"dsr\":[52,52,null,null]}'/>\n<h2 id=\"Section_1\" data-parsoid='{\"dsr\":[53,66,2,2]}'>Section 1</h2>", |
| 1115 |
"html2html": "<p data-parsoid='{\"dsr\":[0,30,0,0]}'><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[0,30,8,9]}'>==Section 1==</span></p>", |
| 1116 |
"html2wt": "<nowiki>==Section 1==</nowiki>" |
| 1117 |
}, |
| 1118 |
"T88318: p-wrapped dash in table.": { |
| 1119 |
"wt2wt": "{|\n!-\n!-\n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1120 |
"selser [[0,[1,4,3,3,[0,2,3,[2,4,1],2,0],0]]]": "{|\n!-\n!- <!--10ph6xs-->\n|-\n|1sxosdu\n|<small>-</small>\n|1xikuyp<br />1i2om9d\n-\n|12dri8j\n|<br />-\n|}", |
| 1121 |
"selser [[4,1]]": "{|<!--avsco0-->\n!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1122 |
"selser [[2,2]]": "{|<!--198ykec-->\n<!--1ja8163-->!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1123 |
"selser [2]": "1qlsswu\n{|\n!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1124 |
"selser [[2,1]]": "{|<!--g6mv6-->\n!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1125 |
"selser [[3,1]]": "{|\n!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1126 |
"selser [[4,[0,4,4,3,1,4]]]": "{|<!--sz0yg8-->\n!-\n!- <!--ammywp--><!--1qztxse-->\n|- data-foobar=\"x39tdc\"\n|<small>-</small>\n|<br />\n-\n|<br />-<!--5q1uzu-->\n|}", |
| 1127 |
"selser [1]": "{| data-foobar=\"1eth3uj\"\n!-\n!- \n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|-\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1128 |
"selser [[4,[[3,3,[2]],3,[0,0,0,1],4,[0,2,3,[0,4,[3]],0,[3,3]],0]]]": "{|<!--lfm8t7-->\n!1r6l1p8- \n|-\n|<nowiki>-</nowiki>\n| data-foobar=\"15cp7gd\" |<nowiki>- </nowiki><!--14jqi8b-->\n|-\n|1o8h1ob\n|<small>-</small>\n|<br />1d00lsm\n|\n|}", |
| 1129 |
"selser [[3,[1,0,3,4,[2,[2],3,1,3,[0,4]],4]]]": "{|\n!-\n!- \n<!--6f0mue-->|-\n|1qnprdx\n|nxpi5d<small>-</small>\n| data-foobar=\"j5al7i\" |<br />\n-\n|<br />11v0cd4<!--1nx3jrc-->\n|}", |
| 1130 |
"selser [[0,[2,3,2,0,1,0]]]": "{|\n<!--1guo0fq-->!-\n!- <!--ude1c1-->\n|-\n|<nowiki>-</nowiki>\n|<nowiki>- </nowiki>\n|- data-foobar=\"arur3a\"\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}", |
| 1131 |
"selser [[4,[[2,4,0],4,[0,[3],4,1],3,[0,2,0,[2,2,0],2,[0,3]],0]]]": "{|<!--1umn7ye-->\n!gvfg8v\n!-\n!15hviht\n!- <!--sgt3q3-->\n|-\n|\n|kkn25m\n| data-foobar=\"1n0s8vl\" |<nowiki>- </nowiki>\n|-\n|158hpl0\n|<small>-</small>\n|3mzszf<br />4wyn44\n-\n|yfh4qc\n|<br />\n|}", |
| 1132 |
"selser [[0,[[2,3,1],2,3,3,1,0]]]": "{|\n!esps5t\n!-\n! data-foobar=\"i5sm52\" |- <!--1ot4a6a-->\n|- data-foobar=\"ogk7sg\"\n|<small>-</small>\n|<br />\n-\n|<br />-\n|}" |
| 1133 |
}, |
| 1134 |
"Table attribute legitimate extension": { |
| 1135 |
"wt2wt": "{|\n! style=\"<nowiki>color:blue</nowiki>\" + |status\n|}", |
| 1136 |
"html2wt": "{|\n! style=\"color:blue\" |status\n|}", |
| 1137 |
"selser [[0,1]]": "{|\n!+ style=\"<nowiki>color:blue</nowiki>\"|status\n|}", |
| 1138 |
"selser [[0,[1,4]]]": "{|\n!+ style=\"<nowiki>color:blue</nowiki>\"|status<!--i3j5qr-->\n|}", |
| 1139 |
"selser [2]": "1jj0mbc\n{|\n!+ style=\"<nowiki>color:blue</nowiki>\"|status\n|}", |
| 1140 |
"selser [[3,2]]": "{|<!--1pefuag-->\n!+ style=\"<nowiki>color:blue</nowiki>\"|status\n|}", |
| 1141 |
"selser [1]": "{| data-foobar=\"buhzkf\"\n!+ style=\"<nowiki>color:blue</nowiki>\"|status\n|}", |
| 1142 |
"selser [[0,[[[2]],2]]]": "{|\n!+ style=\"<nowiki>color:blue</nowiki>\"|ppiy4vstatus<!--ttb0cn-->\n|}" |
| 1143 |
}, |
| 1144 |
"Table attribute safety": { |
| 1145 |
"wt2wt": "{|\n! style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\" + |status\n|}", |
| 1146 |
"html2wt": "{|\n! style=\"/* insecure input */\" |status\n|}", |
| 1147 |
"selser [[4,1]]": "{|<!--d17dj0-->\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1148 |
"selser [[4,[0,2]]]": "{|<!--cn6lpu-->\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status<!--tgejgq-->\n|}", |
| 1149 |
"selser [[3,2]]": "{|<!--mix77b-->\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1150 |
"selser [1]": "{| data-foobar=\"q2fkfw\"\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1151 |
"selser [2]": "105b1n6\n{|\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1152 |
"selser [[0,2]]": "{|\n<!--1imb6os-->!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1153 |
"selser [[0,[[[2]],0]]]": "{|\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|ik2vnbstatus\n|}", |
| 1154 |
"selser [[0,[2,0]]]": "{|\n<!--mblvqc-->!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1155 |
"selser [[0,[0,3]]]": "{|\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status\n|}", |
| 1156 |
"selser [[0,[1,2]]]": "{|\n!+ style=\"<nowiki>border-width:expression(0+alert(document.cookie))</nowiki>\"|status<!--1500efe-->\n|}" |
| 1157 |
}, |
| 1158 |
"Table multiple attributes correction": { |
| 1159 |
"wt2wt": "{|\n! class=\"awesome\" + |status\n|}", |
| 1160 |
"html2wt": "{|\n! class=\"awesome\" |status\n|}", |
| 1161 |
"selser [2]": "gfmvbo\n{|\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1162 |
"selser [1]": "{| data-foobar=\"e4w1bj\"\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1163 |
"selser [[4,[[[2]],0]]]": "{|<!--15iehgr-->\n!+ class=\"error\" class=\"awesome\"|12qkhsgstatus\n|}", |
| 1164 |
"selser [[0,2]]": "{|\n<!--1cmivxo-->!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1165 |
"selser [[0,[1,3]]]": "{|\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1166 |
"selser [[3,1]]": "{|\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1167 |
"selser [[4,1]]": "{|<!--1p4ogrq-->\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1168 |
"selser [[3,2]]": "{|<!--1uwfdeu-->\n!+ class=\"error\" class=\"awesome\"|status\n|}", |
| 1169 |
"selser [[0,[2,0]]]": "{|\n<!--1hgrgiu-->!+ class=\"error\" class=\"awesome\"|status\n|}" |
| 1170 |
}, |
| 1171 |
"Template as link source": { |
| 1172 |
"html2wt": "[[Main Page]]\n\n[[Main Page]]\n\n[[Main Page]]Page\n", |
| 1173 |
"selser [0,4,[2],0,[1,0]]": "[[{{linktest2}}]]\n\npxk4qe\n\nfgwnub[[{{linktest2}}]]\n\n[[{{linktest2}}]]Page", |
| 1174 |
"selser [[3],2,[[3]],3,[3,0]]": "\n\nn2eent\n\nPage", |
| 1175 |
"selser [0,4,1,0,1]": "[[{{linktest2}}]]\n\n1rraqx1\n\n[[{{linktest2}}]]\n\n[[{{linktest2}}]]Page", |
| 1176 |
"selser [2,2,[2],0,3]": "e4ict0\n\n[[{{linktest2}}]]\n\n1gd33w0\n\nd5dd2m[[{{linktest2}}]]\n" |
| 1177 |
}, |
| 1178 |
"Template caching": { |
| 1179 |
"html2wt": "This is a test template\nThis is a test template\n" |
| 1180 |
}, |
| 1181 |
"Template from main namespace": { |
| 1182 |
"html2wt": "blah blah\n" |
| 1183 |
}, |
| 1184 |
"Template from non-includable namespace": { |
| 1185 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,13,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[0,13,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"uh oh!\"}},\"i\":0}}]}'>uh oh!</span></p>", |
| 1186 |
"html2wt": "[[Template:1x]]\n" |
| 1187 |
}, |
| 1188 |
"Template parameter": { |
| 1189 |
"html2wt": "This is a test template with parameter foo\n" |
| 1190 |
}, |
| 1191 |
"Template parameter as link source": { |
| 1192 |
"html2wt": "[[Main Page|link]]\n" |
| 1193 |
}, |
| 1194 |
"Template passing argument to another template": { |
| 1195 |
"html2wt": "including another template, This is a test template with parameter 'hmm'\n" |
| 1196 |
}, |
| 1197 |
"Template unnamed parameter": { |
| 1198 |
"html2wt": "[[Main Page|the main page]]\n" |
| 1199 |
}, |
| 1200 |
"Template with argument in separate line": { |
| 1201 |
"wt2wt": "{{templateasargtest |\n templ = simple }}", |
| 1202 |
"html2wt": "(test)\n", |
| 1203 |
"selser [1]": "{{ templateasargtest |\n templ = simple }}", |
| 1204 |
"selser [2]": "160j7hh\n\n{{ templateasargtest |\n templ = simple }}" |
| 1205 |
}, |
| 1206 |
"Template with complex arguments": { |
| 1207 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,106,0,0]}'><a rel=\"mw:WikiLink\" href=\"./Template:Complextemplate\" title=\"Template:Complextemplate\" about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"stx\":\"piped\",\"a\":{\"href\":\"./Template:Complextemplate\"},\"sa\":{\"href\":\"Template:complextemplate\"},\"pi\":[[{\"k\":\"param\",\"named\":true,\"spc\":[\"\\n \",\" \",\"\",\"\"]},{\"k\":\"1\"}]],\"dsr\":[0,106,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"complextemplate\",\"href\":\"./Template:Complextemplate\"},\"params\":{\"param\":{\"wt\":\"{{ templateasargtest |\\n templ = simple }}\"},\"1\":{\"wt\":\"[[Template:complextemplate|link]]\"}},\"i\":0}}]}'>link</a><span about=\"#mwt1\"> This is a test template with parameter (test)</span></p>", |
| 1208 |
"html2wt": "[[Template:Complextemplate|link]] This is a test template with parameter (test)\n" |
| 1209 |
}, |
| 1210 |
"Template with complex template as argument": { |
| 1211 |
"html2wt": "This is a test template with parameter (test)\n" |
| 1212 |
}, |
| 1213 |
"Template with default value": { |
| 1214 |
"html2wt": "(test)\n" |
| 1215 |
}, |
| 1216 |
"Template with default value (value set)": { |
| 1217 |
"html2wt": "'''templ'''\n" |
| 1218 |
}, |
| 1219 |
"Template with explicit namespace": { |
| 1220 |
"html2wt": "This is a test template\n" |
| 1221 |
}, |
| 1222 |
"Template with invalid target containing tags": { |
| 1223 |
"wt2wt": "<nowiki>{{a</nowiki><b>b</b>|{{1x|foo}}|{{1x|a}}={{1x|b}}<nowiki>|a = b}}</nowiki>", |
| 1224 |
"html2wt": "<nowiki>{{a</nowiki>'''b'''<nowiki>|foo|a=b|a = b}}</nowiki>\n", |
| 1225 |
"selser [2]": "6m3b6y\n\n{{a<b>b</b>|{{1x|foo}}|{{1x|a}}={{1x|b}}|a = b}}", |
| 1226 |
"selser [[3,3,3,0,4,0,2,0,0]]": "{{1x|foo}}napzwa{{1x|a}}iofwsk={{1x|b}}|a = b}}", |
| 1227 |
"selser [[3,[4],2,0,0,0,3,0,0]]": "<b>1xxs67g</b>uckcy2|{{1x|foo}}|{{1x|a}}{{1x|b}}|a = b}}", |
| 1228 |
"selser [1]": "<nowiki>{{a</nowiki><b>b</b>|{{1x|foo}}|{{1x|a}}={{1x|b}}|a = b}}", |
| 1229 |
"selser [[2,[2],4,0,2,0,0,0,0]]": "<nowiki>9xe14n{{a</nowiki><b>eohk8ob</b>60vmj7{{1x|foo}}1i8dgjo|{{1x|a}}={{1x|b}}|a = b}}", |
| 1230 |
"selser [[0,[2],2,0,0,0,3,0,0]]": "<nowiki>{{a</nowiki><b>1orfzvwb</b>1k84mlk|{{1x|foo}}|{{1x|a}}{{1x|b}}|a = b}}", |
| 1231 |
"selser [[0,2,0,0,0,0,4,0,0]]": "<nowiki>{{aruce93</nowiki><b>b</b>|{{1x|foo}}|{{1x|a}}1klwcjt{{1x|b}}|a = b}}", |
| 1232 |
"selser [[2,0,0,0,4,0,0,0,0]]": "<nowiki>9lhhf6{{a</nowiki><b>b</b>|{{1x|foo}}10rdcyk{{1x|a}}={{1x|b}}|a = b}}", |
| 1233 |
"selser [[0,0,4,0,0,0,0,0,0]]": "<nowiki>{{a</nowiki><b>b</b>112xyy0{{1x|foo}}|{{1x|a}}={{1x|b}}|a = b}}", |
| 1234 |
"selser [[4,1,0,0,4,0,3,0,0]]": "t9hq36<b data-foobar=\"ngjfip\">b</b>|{{1x|foo}}hc4wv8{{1x|a}}{{1x|b}}|a = b}}" |
| 1235 |
}, |
| 1236 |
"Template with invalid target containing wikilink": { |
| 1237 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,17,0,0]}'>{{<a rel=\"mw:WikiLink\" href=\"./Main_Page\" title=\"Main Page\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Main_Page\"},\"sa\":{\"href\":\"Main Page\"},\"dsr\":[2,15,2,2]}'>Main Page</a>}}</p>", |
| 1238 |
"wt2wt": "<nowiki>{{</nowiki>[[Main Page]]<nowiki>}}</nowiki>", |
| 1239 |
"html2html": "<p data-parsoid='{\"dsr\":[0,17,0,0]}'>{{<a rel=\"mw:WikiLink\" href=\"./Main_Page\" title=\"Main Page\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Main_Page\"},\"sa\":{\"href\":\"Main Page\"},\"dsr\":[2,15,2,2]}'>Main Page</a>}}</p>", |
| 1240 |
"selser [2]": "gmc0h9\n\n{{[[Main Page]]}}", |
| 1241 |
"selser [1]": "<nowiki>{{</nowiki>[[Main Page]]}}", |
| 1242 |
"selser [[3,0,0]]": "[[Main Page]]}}", |
| 1243 |
"selser [[0,1,0]]": "<nowiki>{{</nowiki>[[Main Page]]}}", |
| 1244 |
"selser [[2,0,0]]": "<nowiki>kjffgy{{</nowiki>[[Main Page]]}}", |
| 1245 |
"selser [[0,[2],0]]": "<nowiki>{{</nowiki>[[Main Page|34249sMain Page]]}}", |
| 1246 |
"selser [[4,2,0]]": "81pro31xhenjk[[Main Page]]}}", |
| 1247 |
"selser [[3,[4],0]]": "[[Main Page|1787260]]}}" |
| 1248 |
}, |
| 1249 |
"Template with just whitespace in it, T70421": { |
| 1250 |
"html2html": "<p data-parsoid='{\"dsr\":[0,29,0,0]}'>{{1x|{{ }<span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[9,27,8,9]}'>}</span>}}</p>" |
| 1251 |
}, |
| 1252 |
"Template with template name as argument": { |
| 1253 |
"html2wt": "(test)\n" |
| 1254 |
}, |
| 1255 |
"Template with template name as argument (2)": { |
| 1256 |
"html2wt": "(test)\n" |
| 1257 |
}, |
| 1258 |
"Template with template name as unnamed argument": { |
| 1259 |
"html2wt": "(test)\n" |
| 1260 |
}, |
| 1261 |
"Templates with templated name": { |
| 1262 |
"html2html": "<p data-parsoid='{\"dsr\":[0,39,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[0,17,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"{{1x|1x}}\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span>\n{<span about=\"#mwt3\" typeof=\"mw:Param\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[19,38,null,null]}' data-mw='{\"parts\":[{\"templatearg\":{\"target\":{\"wt\":\"1x\"},\"params\":{\"1\":{\"wt\":\"inner list\"}},\"i\":0}}]}'>inner list</span>}</p>", |
| 1263 |
"html2wt": "{{{{1x|1x}}|foo}}\n{{{{1x|inner list}}}}" |
| 1264 |
}, |
| 1265 |
"Templates: 1. Simple use": { |
| 1266 |
"html2wt": "Foo\n" |
| 1267 |
}, |
| 1268 |
"Templates: 2. Inside a block tag": { |
| 1269 |
"html2wt": "<div>Foo</div>\n<blockquote>Foo</blockquote>" |
| 1270 |
}, |
| 1271 |
"Templates: Block Tags: 1. Multiple template uses": { |
| 1272 |
"html2wt": "<div>Foo</div><div>bar</div><div>baz</div>" |
| 1273 |
}, |
| 1274 |
"Templates: Block Tags: 2. Back-to-back template uses": { |
| 1275 |
"html2wt": "<div>Foo</div><div>bar</div>" |
| 1276 |
}, |
| 1277 |
"Templates: Don't strip whitespace from positional-param values": { |
| 1278 |
"html2html": "<p data-parsoid='{\"dsr\":[0,8,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[0,8,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"a\"}},\"i\":0}}]}'>a</span></p>\n\n<p data-parsoid='{\"dsr\":[10,26,0,0]}'><span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[10,26,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"{{1x|b}} \"}},\"i\":0}}]}'>b </span></p>\n\n<pre about=\"#mwt4\" typeof=\"mw:Transclusion\" data-parsoid='{\"dsr\":[28,39,1,0],\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\" c \\n\"}},\"i\":0}}]}'>c </pre><span about=\"#mwt4\">\n</span>\n\n<pre about=\"#mwt5\" typeof=\"mw:Transclusion\" data-parsoid='{\"dsr\":[41,58,1,0],\"pi\":[[{\"k\":\"1\"}]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\" {{1x|d}}\\n\"}},\"i\":0}}]}'>d</pre><span about=\"#mwt5\">\n</span>\n\n<span about=\"#mwt7\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[60,70,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"\\n e\"}},\"i\":0}}]}'>\n</span><pre about=\"#mwt7\">e</pre>\n\n<ul about=\"#mwt8\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[72,82,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"\\n*f\"}},\"i\":0}}]}'><li>f</li></ul>\n\n<span about=\"#mwt9\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[84,94,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"\\n \"}},\"i\":0}},\"g\"]}'>\n</span><pre about=\"#mwt9\">g</pre>\n", |
| 1279 |
"html2wt": "{{1x|a}}\n\n{{1x|{{1x|b}} }}\n\n{{1x| c \n}}\n\n{{1x| {{1x|d}}\n}}\n\n{{1x|\n e}}\n\n{{1x|\n*f}}\n\n{{1x|\n }}g\n" |
| 1280 |
}, |
| 1281 |
"Templates: HTML Tables: 1. Generating start of a HTML table": { |
| 1282 |
"html2wt": "{|\n|foo\n|}" |
| 1283 |
}, |
| 1284 |
"Templates: HTML Tables: 2a. Generating middle of a HTML table": { |
| 1285 |
"html2wt": "{|\n|foo\n|}" |
| 1286 |
}, |
| 1287 |
"Templates: HTML Tables: 2b. Generating middle of a HTML table": { |
| 1288 |
"html2wt": "{|\n|foo\n|}" |
| 1289 |
}, |
| 1290 |
"Templates: HTML Tables: 3. Generating end of a HTML table": { |
| 1291 |
"html2wt": "{|\n|foo\n|}" |
| 1292 |
}, |
| 1293 |
"Templates: HTML Tables: 4a. Generating a single tag of a HTML table": { |
| 1294 |
"html2wt": "{|\n|foo\n|}" |
| 1295 |
}, |
| 1296 |
"Templates: HTML Tables: 4b. Generating a single tag of a HTML table": { |
| 1297 |
"html2wt": "{|\n|foo\n|}" |
| 1298 |
}, |
| 1299 |
"Templates: HTML Tables: 4c. Generating a single tag of a HTML table": { |
| 1300 |
"html2wt": "{|\n|foo\n|}" |
| 1301 |
}, |
| 1302 |
"Templates: HTML Tables: 4d. Generating a single tag of a HTML table": { |
| 1303 |
"html2wt": "{|\n|foo\n|}" |
| 1304 |
}, |
| 1305 |
"Templates: HTML Tables: 4e. Generating a single tag of a HTML table": { |
| 1306 |
"html2wt": "{|\n|foo\n|}" |
| 1307 |
}, |
| 1308 |
"Templates: HTML Tables: 4f. Generating a single tag of a HTML table": { |
| 1309 |
"html2wt": "{|\n|foo\n|}" |
| 1310 |
}, |
| 1311 |
"Templates: HTML Tables: 5. Proper fostering of categories from inside": { |
| 1312 |
"wt2wt": "[[Category:foo1]]\n<table><tr><td>foo</td></tr></table>\n<!--Two categories (T52330)-->\n[[Category:bar1]]\n[[Category:bar2]]\n<table><tr><td>foo</td></tr></table>", |
| 1313 |
"selser [0,4,3,3,0,0,3,1]": "\n19h1ld5\n\n<table data-foobar=\"exxatp\">[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1314 |
"selser [0,[3],0,0,3,0,4,2]": "<table></table>\n<!--Two categories (T52330)-->\n87j86d\n\n1f0erjx<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1315 |
"selser [4,1,3,2,2,2,0,2]": "19xyk39<table data-foobar=\"1qcb51b\"><tr><td>foo</td></tr></table>1o0d9it<!--Two categories (T52330)-->3lz621\n1bgu2v5\n\n12i5r36<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1316 |
"selser [0,4,2,4,2,1,0,1]": "\npn4gr3\n\n1lihmsq\n\nd9y1hz\n\n1rj5xqn\n[[Category:bar1]]<table data-foobar=\"1eie4b1\">[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1317 |
"selser [3,[[3]],3,2,0,4,0,4]": "<table></table>1amt4y8<!--Two categories (T52330)-->\neqzawk\n\n14qwron", |
| 1318 |
"selser [1,3,0,4,0,0,0,[[[[3]]]]]": "[[Category:foo1]]\n4wwu7l\n<table><tr><td></td></tr></table>", |
| 1319 |
"selser [3,2,3,2,2,0,0,[[[[2]]]]]": "17g3f08<table>[[Category:foo1]]<tr><td>foo</td></tr></table>98bgxd<!--Two categories (T52330)-->5w164m\n<table><tr><td>gllkrhfoo</td></tr></table>", |
| 1320 |
"selser [1,2,0,0,4,0,0,1]": "[[Category:foo1]]\nu53ooc<table>[[Category:foo1]]<tr><td>foo</td></tr></table>\n<!--Two categories (T52330)-->1yiap4j\n<table data-foobar=\"1pkwb5z\">[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1321 |
"selser [0,1,4,0,0,0,1,[1]]": "<table data-foobar=\"1ao67b1\">[[Category:foo1]]<tr><td>foo</td></tr></table>1qf8oge<!--Two categories (T52330)-->\n[[Category:bar2]]<table><tr><td>foo</td></tr></table>", |
| 1322 |
"selser [4,3,0,2,2,0,0,[2]]": "1iafpl4\n\n6kydpl<!--Two categories (T52330)-->\n\n15ckbun\n<table><!--zfemic-->[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1323 |
"selser [2,3,4,2,3,0,0,0]": "1ruq81a\n\n1qw8sl4\n\n1qejmyr<!--Two categories (T52330)-->\n<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1324 |
"selser [4,1,0,2,0,0,3,2]": "5hz3aw<table data-foobar=\"upzbpv\"><tr><td>foo</td></tr></table>\ncwe6qn<!--Two categories (T52330)-->\n\ngqnxgh<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1325 |
"selser [0,3,2,4,3,3,0,4]": "\nog20f2\n\noew26\n\n14dtcb7", |
| 1326 |
"selser [0,2,4,4,4,4,2,0]": "\n9681q6<table>[[Category:foo1]]<tr><td>foo</td></tr></table>9v9qhb\n\n7f819c\n\n1a1swkg\n\nfktl95\n\nlid51k\n<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1327 |
"selser [0,3,2,0,2,4,0,2]": "\nuwa66g\n<!--Two categories (T52330)-->\n13g5uav\n\n1reh495\n\n1dr806a<table>[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1328 |
"selser [2,3,2,2,0,0,0,[[4]]]": "187345c\n\n1f6yku\n\n152w7ze<!--Two categories (T52330)-->\n<table><!--12qheqo--></table>", |
| 1329 |
"selser [0,1,4,0,0,0,1,[2]]": "<table data-foobar=\"14spsos\">[[Category:foo1]]<tr><td>foo</td></tr></table>nfwv7p<!--Two categories (T52330)-->\n[[Category:bar2]]<table><!--1eg7h61-->[[Category:bar1]][[Category:bar2]]<tr><td>foo</td></tr></table>", |
| 1330 |
"selser [0,[2],0,2,2,0,0,[1]]": "<table><!--z6fyce-->[[Category:foo1]]<tr><td>foo</td></tr></table>\nidlxej<!--Two categories (T52330)-->\n\n188n4it\n<table><tr><td>foo</td></tr></table>", |
| 1331 |
"selser [0,[[3]],2,0,0,4,0,[[[4]]]]": "<table></table>2bm4an\n<!--Two categories (T52330)-->\nhvw0xo\n<table><tr><td>19l0hr1</td></tr></table>", |
| 1332 |
"selser [0,4,4,0,0,3,2,[3]]": "\ng5pbjc\n\n1uawsi1<!--Two categories (T52330)-->\n\nxxbxzn\n<table></table>" |
| 1333 |
}, |
| 1334 |
"Templates: HTML Tag: 1. Generation of HTML attr. key": { |
| 1335 |
"html2wt": "<div style=\"color:red;\">foo</div>" |
| 1336 |
}, |
| 1337 |
"Templates: HTML Tag: 2. Generation of HTML attr. value": { |
| 1338 |
"wt2html": "<div style=\"'color:red;'\" about=\"#mwt2\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"a\":{\"style\":\"'color:red;'\"},\"sa\":{\"style\":\"{{1x|'color:red;'}}\"},\"dsr\":[0,40,31,6]}' data-mw='{\"attribs\":[[{\"txt\":\"style\"},{\"html\":\"<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"}]],\\\"dsr\\\":[11,30,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"1x\\\",\\\"href\\\":\\\"./Template:1x\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"&apos;color:red;&apos;\\\"}},\\\"i\\\":0}}]}'>'color:red;'</span>\"}]]}'>foo</div>", |
| 1339 |
"wt2wt": "<div style=\"{{1x|'color:red;'}}\">foo</div>", |
| 1340 |
"html2wt": "<div style=\"color:red;\">foo</div>", |
| 1341 |
"selser [[4]]": "<div style={{1x|'color:red;'}}>st8w6k</div>", |
| 1342 |
"selser [[3]]": "<div style={{1x|'color:red;'}}></div>", |
| 1343 |
"selser [2]": "j1h7tb<div style={{1x|'color:red;'}}>foo</div>", |
| 1344 |
"selser [[2]]": "<div style={{1x|'color:red;'}}>1t5bf2jfoo</div>" |
| 1345 |
}, |
| 1346 |
"Templates: HTML Tag: 3. Generation of HTML attr key and value": { |
| 1347 |
"wt2html": "<div style=\"'color:red;'\" about=\"#mwt3\" typeof=\"mw:ExpandedAttrs\" data-parsoid='{\"stx\":\"html\",\"a\":{\"style\":\"'color:red;'\"},\"sa\":{\"style\":\"{{1x|'color:red;'}}\"},\"dsr\":[0,47,38,6]}' data-mw='{\"attribs\":[[{\"txt\":\"style\",\"html\":\"<span about=\\\"#mwt2\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"}]],\\\"dsr\\\":[5,17,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"1x\\\",\\\"href\\\":\\\"./Template:1x\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"style\\\"}},\\\"i\\\":0}}]}'>style</span>\"},{\"html\":\"<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[{\\\"k\\\":\\\"1\\\"}]],\\\"dsr\\\":[18,37,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"1x\\\",\\\"href\\\":\\\"./Template:1x\\\"},\\\"params\\\":{\\\"1\\\":{\\\"wt\\\":\\\"&apos;color:red;&apos;\\\"}},\\\"i\\\":0}}]}'>'color:red;'</span>\"}]]}'>foo</div>", |
| 1348 |
"wt2wt": "<div {{1x|style}}=\"{{1x|'color:red;'}}\">foo</div>", |
| 1349 |
"html2wt": "<div style=\"color:red;\">foo</div>", |
| 1350 |
"selser [2]": "pdx0f1<div {{1x|style}}={{1x|'color:red;'}}>foo</div>", |
| 1351 |
"selser [[2]]": "<div {{1x|style}}={{1x|'color:red;'}}>or4lrdfoo</div>", |
| 1352 |
"selser [[3]]": "<div {{1x|style}}={{1x|'color:red;'}}></div>", |
| 1353 |
"selser [[4]]": "<div {{1x|style}}={{1x|'color:red;'}}>1olq5ql</div>" |
| 1354 |
}, |
| 1355 |
"Templates: HTML Tag: 4. Generation of starting piece of HTML attr value": { |
| 1356 |
"html2wt": "<div title=\"This is a long title with just one piece templated\">foo</div>" |
| 1357 |
}, |
| 1358 |
"Templates: HTML Tag: 5. Generation of middle piece of HTML attr value": { |
| 1359 |
"html2wt": "<div title=\"This is a long title with just one piece templated\">foo</div>" |
| 1360 |
}, |
| 1361 |
"Templates: HTML Tag: 6. Generation of end piece of HTML attr value": { |
| 1362 |
"html2wt": "<div title=\"This is a long title with just one piece templated\">foo</div>" |
| 1363 |
}, |
| 1364 |
"Templates: HTML Tag: 7. Generation of partial attribute key string": { |
| 1365 |
"html2wt": "<div style=\"color:red;\">foo</div>" |
| 1366 |
}, |
| 1367 |
"Templates: HTML Tag: 8. Template-generated attribute (k=v)": { |
| 1368 |
"html2wt": "<div id=\"v1\">bar</div>" |
| 1369 |
}, |
| 1370 |
"Templates: HTML Tag: 9. Multiple template-generated attributes": { |
| 1371 |
"wt2wt": "<div {{1x|1=id=\"v1\" title=\"foo\"}} title=\"foo\">bar</div>", |
| 1372 |
"html2wt": "<div id=\"v1\" title=\"foo\">bar</div>", |
| 1373 |
"selser [2]": "p24rfu<div {{1x|1=id=\"v1\" title=\"foo\"}}>bar</div>", |
| 1374 |
"selser [[4]]": "<div {{1x|1=id=\"v1\" title=\"foo\"}}>le9cq8</div>", |
| 1375 |
"selser [[2]]": "<div {{1x|1=id=\"v1\" title=\"foo\"}}>1bxu541bar</div>", |
| 1376 |
"selser [[3]]": "<div {{1x|1=id=\"v1\" title=\"foo\"}}></div>" |
| 1377 |
}, |
| 1378 |
"Templates: Handle comments in parameter names (T69657)": { |
| 1379 |
"html2wt": "{{1x|1\n<!-- should be ignored -->=foo}}\n\n{{1x|<!-- should be ignored -->\n1=foo}}\n\n{{1x|1<!-- should be ignored -->=foo}}\n\n{{1x|<!-- should be ignored -->1=foo}}" |
| 1380 |
}, |
| 1381 |
"Templates: Handle comments in the target": { |
| 1382 |
"wt2wt": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{1x|foo}}", |
| 1383 |
"html2html": "<p data-parsoid='{\"dsr\":[0,37,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[0,37,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\\n<!-- should be ignored -->\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span></p>\n\n<p data-parsoid='{\"dsr\":[39,132,0,0]}'><span about=\"#mwt2\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[39,132,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span></p>\n\n<p data-parsoid='{\"dsr\":[134,170,0,0]}'><span about=\"#mwt3\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[134,170,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x<!-- should be ignored -->\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span></p>\n\n<p data-parsoid='{\"dsr\":[172,208,0,0]}'><span about=\"#mwt4\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[172,208,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x<!-- should be ignored -->\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span></p>\n\n<p data-parsoid='{\"dsr\":[210,220,0,0]}'><span about=\"#mwt5\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[210,220,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"foo\"}},\"i\":0}}]}'>foo</span></p>", |
| 1384 |
"html2wt": "{{1x\n<!-- should be ignored -->|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{1x|foo}}", |
| 1385 |
"selser [0,0,0,0,0,3,1,2,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n11s4vri\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1386 |
"selser [0,3,2,2,0,0,0,2,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\nx9t199\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\njf19e9\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\ne3eyak\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1387 |
"selser [0,3,0,0,0,0,4,3,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n1or8ult\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1388 |
"selser [0,3,0,2,0,0,0,0,2]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n3kje4\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\nhjntaw\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1389 |
"selser [0,3,0,4,0,0,0,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n19mqg7x\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1390 |
"selser [0,0,2,0,1,3,0,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n7b24db\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1391 |
"selser [0,0,0,3,0,2,4,4,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n1ja78u2\n\n1dx8rel\n\n16zh6f8\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1392 |
"selser [0,2,0,0,4,4,1,0,2]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n9y49hn\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n1ddrh7k\n\nusdnpp\n\n{{1x<!-- should be ignored -->|foo}}\n\nojmq1t\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1393 |
"selser [4,3,0,0,2,0,3,0,0]": "1mf1wb2\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n12ltey2\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1394 |
"selser [0,0,0,4,0,3,4,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n15kz7wx\n\n{{1x<!-- should be ignored -->\n|foo}}\n\nrrsz5e\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1395 |
"selser [0,2,3,4,3,0,1,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n1tk3qw5\n\n1hbje26\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1396 |
"selser [1,2,2,0,0,3,1,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n1vdnldk\n\nljxuak\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1397 |
"selser [0,0,0,0,0,0,4,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\nwikvcr\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1398 |
"selser [4,4,3,0,3,0,0,2,0]": "1io1y5h\n\nd6x522\n\n{{1x<!-- should be ignored -->|foo}}\n\n1yybzd6\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1399 |
"selser [3,0,1,0,1,0,0,4,0]": "\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n2bjd83\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1400 |
"selser [2,3,0,2,0,0,0,0,0]": "1p7jro6\n\n{{1x\n<!-- should be ignored -->\n|foo}}\n\n{{1x\n<!-- should be ignored and spaces on next line should not trip us up (T147742) -->\n |foo}}\n\n1sfbaik\n\n{{1x<!-- should be ignored -->\n|foo}}\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}", |
| 1401 |
"selser [0,0,4,0,0,2,0,0,0]": "{{1x\n<!-- should be ignored -->\n|foo}}\n\n10zfktk\n\n{{1x<!-- should be ignored -->\n|foo}}\n\nahtv70\n\n{{1x<!-- should be ignored -->|foo}}\n\n{{<!-- should be ignored -->1x|foo}}" |
| 1402 |
}, |
| 1403 |
"Templates: Inline Text: 1. Multiple template uses": { |
| 1404 |
"html2wt": "Foobarbaz\n" |
| 1405 |
}, |
| 1406 |
"Templates: Inline Text: 2. Back-to-back template uses": { |
| 1407 |
"html2wt": "Foobar\n" |
| 1408 |
}, |
| 1409 |
"Templates: Links: 1. Simple example": { |
| 1410 |
"html2wt": "[[Foo|bar]]\n" |
| 1411 |
}, |
| 1412 |
"Templates: Links: 2. Generation of link href": { |
| 1413 |
"html2wt": "[[Foo|bar]]\n" |
| 1414 |
}, |
| 1415 |
"Templates: Links: 3. Generation of part of a link href": { |
| 1416 |
"selser [3,2,[[3]],0,4,2,[[3]],4,[1],4,[2]]": "aywe6t\n\n2atoa8\n\n1byy9q\n\n1o38tet\n\n[[:Foo{{1x|bar}}]]\n\n1dte6r9\n\ns1p4mx[[:Foo{{1x|bar}}|bar]]", |
| 1417 |
"selser [0,4,4,0,1,0,[3],0,0,0,4]": "[[Fo{{1x|o}}|bar]]\n\n1c1r7lu\n\n1o3oo46\n\n[[Foo{{1x|bar}}baz]]\n\n[[:Foo{{1x|bar}}]]\n\n1iow8d2", |
| 1418 |
"selser [[[3]],3,4,3,[1],0,[[4]],0,[4],2,[[4]]]": "\n1pm7qe5\n\n[[Foo{{1x|bar}}baz]]\n\n[[Foo{{1x|bar}}|1vrh4rz]]\n\n4pyayk\n\n1i2zpn1\n\n[[:Foo{{1x|bar}}|1kp3plh]]", |
| 1419 |
"selser [3,0,1,4,[3],4,4,0,[[3]],0,0]": "\n[[Foo{{1x|bar}}]]\n\n999g2f\n\n\n1hm4i9h\n\n1feh9l\n\n[[:Foo{{1x|bar}}|bar]]" |
| 1420 |
}, |
| 1421 |
"Templates: Links: 5. Generation of link text": { |
| 1422 |
"html2wt": "[[Foo|bar]]\n" |
| 1423 |
}, |
| 1424 |
"Templates: Links: 5. Nested templates (only outermost template should be marked)": { |
| 1425 |
"html2wt": "[[Foo|bar]]\n" |
| 1426 |
}, |
| 1427 |
"Templates: Lists: Multi-line list-items via templates": { |
| 1428 |
"html2wt": "* {{1x|a {{nonexistent|\nunused}}}}\n* {{1x|b {{nonexistent|\nunused}}}}" |
| 1429 |
}, |
| 1430 |
"Templates: P-wrapping: 1a. Templates on consecutive lines": { |
| 1431 |
"html2wt": "Foo\nbar\n" |
| 1432 |
}, |
| 1433 |
"Templates: P-wrapping: 1b. Templates on consecutive lines": { |
| 1434 |
"html2wt": "Foo\n\nbar\nbaz\n" |
| 1435 |
}, |
| 1436 |
"Templates: P-wrapping: 1c. Templates on consecutive lines": { |
| 1437 |
"selser [0,0,0,4,2]": "{{1x|Foo}}\n{{1x|bar}}\n\ny6i2wq\n\nwhdbxd<div>baz</div>", |
| 1438 |
"selser [1,0,0,2,1]": "{{1x|Foo}}\n{{1x|bar}}\n\n1gf1ef7 <div data-foobar=\"lzr5vy\">baz</div>" |
| 1439 |
}, |
| 1440 |
"Templates: Strip leading and trailing whitespace from named-param values": { |
| 1441 |
"html2wt": "a\n\nb\n\nc\n\n* d" |
| 1442 |
}, |
| 1443 |
"Templates: Ugly nesting: 1. Quotes opened/closed across templates (1x)": { |
| 1444 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,34,0,0]}'><i about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}],[{\"k\":\"1\"}],[{\"k\":\"1\"}]],\"dsr\":[0,34,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"''a\"}},\"i\":0}},{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"b''c''d\"}},\"i\":1}},{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"''e\"}},\"i\":2}}]}'>ab</i><span about=\"#mwt1\">c</span><i about=\"#mwt1\">d</i><span about=\"#mwt1\">e</span></p>", |
| 1445 |
"html2wt": "''ab''c''d''e\n" |
| 1446 |
}, |
| 1447 |
"Templates: Ugly nesting: 4. Divs opened/closed across templates": { |
| 1448 |
"html2wt": "a<div>bc</div>de" |
| 1449 |
}, |
| 1450 |
"Templates: Ugly templates: 3. newline-only template parameter": { |
| 1451 |
"html2wt": "foo \n" |
| 1452 |
}, |
| 1453 |
"Templates: Ugly templates: 4. newline-only template parameter inconsistency": { |
| 1454 |
"wt2html": "<span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[{\"k\":\"1\"}]],\"dsr\":[0,8,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"1x\",\"href\":\"./Template:1x\"},\"params\":{\"1\":{\"wt\":\"\\n\"}},\"i\":0}}]}'>\n</span>", |
| 1455 |
"html2html": "\n\n", |
| 1456 |
"html2wt": "\n\n" |
| 1457 |
}, |
| 1458 |
"Templates: Wiki Tables: 3. td-content via multiple templates": { |
| 1459 |
"html2wt": "{|\n|ab\n|}" |
| 1460 |
}, |
| 1461 |
"Templates: Wiki Tables: 5. Templated tags, regular td-tags": { |
| 1462 |
"html2wt": "{|\n|foo\n|}" |
| 1463 |
}, |
| 1464 |
"Templates: Wiki Tables: 6. Templated tags, templated td-tags": { |
| 1465 |
"html2wt": "{|\n|foo\n|}" |
| 1466 |
}, |
| 1467 |
"Templates: Wiki Tables: 8. Fosterable meta-tags should get fostered": { |
| 1468 |
"html2html": "<meta typeof=\"mw:Transclusion mw:Includes/OnlyInclude\" about=\"#mwt1\" data-parsoid='{\"dsr\":[0,64,null,null],\"pi\":[[]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"UnclosedTableEndsWithTR\",\"href\":\"./Template:UnclosedTableEndsWithTR\"},\"params\":{},\"i\":0}},\"\\n<onlyinclude>\\n|foo\\n</onlyinclude>\\n|}\"]}'/><table about=\"#mwt1\">\n<tbody><tr>\n\n<td>foo\n<meta typeof=\"mw:Includes/OnlyInclude/End\"/></td></tr>\n</tbody></table>\n<table data-parsoid='{\"dsr\":[65,90,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[68,88,0,0]}'><tr data-parsoid='{\"autoInsertedStart\":true,\"dsr\":[68,87,0,0]}'><td data-parsoid='{\"dsr\":[68,87,1,0]}'>foo\n<meta typeof=\"mw:Includes/OnlyInclude/End\" data-parsoid='{\"src\":\"</onlyinclude>\",\"dsr\":[73,87,null,null]}'/></td></tr>\n</tbody></table>\n\n<meta typeof=\"mw:Includes/NoInclude\" data-parsoid='{\"src\":\"<noinclude>\",\"dsr\":[92,103,null,null]}'/>\n<meta typeof=\"mw:Transclusion mw:Includes/NoInclude/End\" about=\"#mwt2\" data-parsoid='{\"dsr\":[104,152,null,null],\"pi\":[[]]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"UnclosedTableEndsWithTR\",\"href\":\"./Template:UnclosedTableEndsWithTR\"},\"params\":{},\"i\":0}},\"\\n</noinclude>\\n|foo\\n|}\"]}'/><table about=\"#mwt2\">\n<tbody><tr>\n\n<td>foo</td></tr>\n</tbody></table> \n<table data-parsoid='{\"dsr\":[154,164,2,2]}'>\n<tbody data-parsoid='{\"dsr\":[157,162,0,0]}'><tr data-parsoid='{\"autoInsertedStart\":true,\"dsr\":[157,161,0,0]}'><td data-parsoid='{\"dsr\":[157,161,1,0]}'>foo</td></tr>\n</tbody></table>", |
| 1469 |
"html2wt": "{{UnclosedTableEndsWithTR}}\n<onlyinclude>\n|foo\n</onlyinclude>\n|}\n{|\n|foo\n</onlyinclude>\n|}\n\n<noinclude>\n{{UnclosedTableEndsWithTR}}\n</noinclude>\n|foo\n|} \n{|\n|foo\n|}", |
| 1470 |
"selser [0,0,2,3,0,0,0]": "{{UnclosedTableEndsWithTR}}\n<onlyinclude>\n|foo\n</onlyinclude>\n|}\nl010k6\n\n\n{{UnclosedTableEndsWithTR}}\n</noinclude>\n|foo\n|}" |
| 1471 |
}, |
| 1472 |
"Test the li-hack (a hack from Tidy days, but doesn't work as advertised with Remex)": { |
| 1473 |
"selser [[0,2,1,[3,3],3,0,0,3,2,[3]],0,3]": "*foo\n* v8yh25\n*<li>\n*{{1x|<li>templated li-hack}}\n**bar2* ksjd4q\n*<!--foo--><li>\n" |
| 1474 |
}, |
| 1475 |
"Testing serialization after deletion of table cells": { |
| 1476 |
"selser [manual]": "{|\n!h1 !!h2 !!h3\n|c2 |||c3\n|}", |
| 1477 |
"selser [[0,[[2,4,[3],2,3,2,1],0]]]": "{|\n!csxba4\n!h1 \n!t84r7o!!\n!1awkle6\n!1cz1t59\n|c2 || data-foobar=\"ztx97e\"|c3\n|}", |
| 1478 |
"selser [1]": "{| data-foobar=\"1wk5r9j\"\n!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}", |
| 1479 |
"selser [[0,2]]": "{|\n<!--pikbtg-->!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}", |
| 1480 |
"selser [2]": "jjco8\n{|\n!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}", |
| 1481 |
"selser [[4,[[1,[4],2,4,0,0,1],2]]]": "{|<!--1suoukh-->\n! data-foobar=\"rk18oo\" |h1 !!18wtl70 \n!qnyy7b!!h3\n!zs6fgw\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 || data-foobar=\"kaqv9t\"|c3<!--ux8nfz-->\n|}", |
| 1482 |
"selser [[0,[[[2],0,0,2,0,1,0],3]]]": "{|\n!w2yar5h1 !!h2 !!h3\n!bwqkmm\n| id=\"x\" |c1 {{!}}{{!}} data-foobar=\"132iz66\"{{!}}c2 |||c3\n|}", |
| 1483 |
"selser [[2,[[1,0,0,0,1,0,3],0]]]": "{|<!--pql4jf-->\n! data-foobar=\"bhnvrw\" |h1 !!h2 !!h3\n| id=\"x\" data-foobar=\"12hrisq\" |c1 {{!}}{{!}}{{!}}c2 \n|}", |
| 1484 |
"selser [[4,[[1,0,1,0,0,4,4],0]]]": "{|<!--jbstp9-->\n! data-foobar=\"1pn0sp4\" |h1 !!h2 !! data-foobar=\"1f5qbgd\" |h3\n| id=\"x\" |c1 \n|uz7gua\n|vakcz3\n|}", |
| 1485 |
"selser [[0,[2,4]]]": "{|\n<!--5xh8o9-->!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3<!--w8wfis-->\n|}", |
| 1486 |
"selser [[0,1]]": "{|\n!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}", |
| 1487 |
"selser [[2,[[4,1,4,2,0,[4],[4]],3]]]": "{|<!--qcs46g-->\n!11pa019!! data-foobar=\"1y95ntw\" |h2 \n!zdryfg\n!h2f3sk\n| id=\"x\" |c1 {{!}}{{!}}{{!}}r4h39b |||1lmf1dk\n|}", |
| 1488 |
"selser [[4,2]]": "{|<!--cgr2fy--><!--1sny8l1-->\n!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}", |
| 1489 |
"selser [[3,[2,0]]]": "{|<!--1kfzavr-->\n!h1 !!h2 !!h3\n| id=\"x\" |c1 {{!}}{{!}}{{!}}c2 |||c3\n|}" |
| 1490 |
}, |
| 1491 |
"Trailing newlines in a deep dom-subtree that ends a wikitext line should be migrated out": { |
| 1492 |
"wt2wt": "{|\n|<small>foo\n\nbar\n|}\n\n{|\n|<small>foo<small>\n|}", |
| 1493 |
"html2wt": "{|\n|<small>foo\n\nbar\n|}\n\n{|\n|<small>foo<small>\n|}", |
| 1494 |
"selser [2,4,2]": "1vhem8t\n{|\n|<small>foo\nbar\n|}\nh41874\n\n12z4z6q\n{|\n|<small>foo<small>\n|}", |
| 1495 |
"selser [[0,[[1],4]],3,[0,[[[[4,0]]],0]]]": "{|\n| data-foobar=\"1ue1gl4\" |<small>foo\nbar<!--1e5adh6-->\n|}\n{|\n|<small>q5va4q<small>\n|}", |
| 1496 |
"selser [2,0,3]": "16x02uj\n{|\n|<small>foo\nbar\n|}\n", |
| 1497 |
"selser [2,0,[2,[2,0]]]": "520cu8\n{|\n|<small>foo\nbar\n|}\n\n{|<!--1wcfyae-->\n<!--hzgi8f-->|<small>foo<small>\n|}" |
| 1498 |
}, |
| 1499 |
"Transclusion of a child page": { |
| 1500 |
"html2wt": "Sibling article\n" |
| 1501 |
}, |
| 1502 |
"Transclusion of a sibling page (one level up)": { |
| 1503 |
"html2wt": "Sibling article\n" |
| 1504 |
}, |
| 1505 |
"Transclusion with a (stripped) fragment": { |
| 1506 |
"metadata": "" |
| 1507 |
}, |
| 1508 |
"Un-closed <onlyinclude>": { |
| 1509 |
"html2wt": "" |
| 1510 |
}, |
| 1511 |
"Unbalanced closing block tags break a list": { |
| 1512 |
"html2wt": "<div>\n* a\n</div>\n<div>\n* b\n</div>" |
| 1513 |
}, |
| 1514 |
"Unbalanced closing wikitext block tags break a list": { |
| 1515 |
"html2wt": "<p>\n\n* a</p><p>\n\n* b</p>" |
| 1516 |
}, |
| 1517 |
"Unbalanced includeonly and noinclude tags": { |
| 1518 |
"html2wt": "{|\n|a\n|b\n|c</includeonly>\n|d</includeonly></includeonly>\n|}" |
| 1519 |
}, |
| 1520 |
"Using {{!}} in wikilinks (T290526)": { |
| 1521 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,32,0,0]}'><a typeof=\"mw:ExpandedAttrs mw:LocalizedAttrs\" about=\"#mwt2\" rel=\"mw:WikiLink\" href=\"./Main_PageSomething_else?action=edit&redlink=1\" title=\"Main PageSomething else\" class=\"new\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Main_PageSomething_else\"},\"sa\":{\"href\":\"Main Page{{!}}Something else\"},\"dsr\":[0,32,null,null]}' data-mw='{\"attribs\":[[{\"txt\":\"href\"},{\"html\":\"Main Page<span about=\\\"#mwt1\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[]],\\\"dsr\\\":[11,16,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"!\\\",\\\"function\\\":\\\"!\\\"},\\\"params\\\":{},\\\"i\\\":0}}]}'>|</span>Something else\"}]]}' data-mw-i18n='{\"title\":{\"lang\":\"x-page\",\"key\":\"red-link-title\",\"params\":[\"Main PageSomething else\"]}}'>Main PageSomething else</a></p>\n\n<p data-parsoid='{\"dsr\":[34,49,0,0]}'><a typeof=\"mw:ExpandedAttrs mw:LocalizedAttrs\" about=\"#mwt5\" rel=\"mw:WikiLink\" href=\"./Main_PageSomething_else?action=edit&redlink=1\" title=\"Main PageSomething else\" class=\"new\" data-parsoid='{\"stx\":\"simple\",\"a\":{\"href\":\"./Main_PageSomething_else\"},\"sa\":{\"href\":\"{{T290526}}\"},\"dsr\":[34,49,null,null]}' data-mw='{\"attribs\":[[{\"txt\":\"href\"},{\"html\":\"<span about=\\\"#mwt3\\\" typeof=\\\"mw:Transclusion\\\" data-parsoid='{\\\"pi\\\":[[]],\\\"dsr\\\":[36,47,null,null]}' data-mw='{\\\"parts\\\":[{\\\"template\\\":{\\\"target\\\":{\\\"wt\\\":\\\"T290526\\\",\\\"href\\\":\\\"./Template:T290526\\\"},\\\"params\\\":{},\\\"i\\\":0}}]}'>Main Page|Something else</span>\"}]]}' data-mw-i18n='{\"title\":{\"lang\":\"x-page\",\"key\":\"red-link-title\",\"params\":[\"Main PageSomething else\"]}}'>Main PageSomething else</a></p>", |
| 1522 |
"html2wt": "[[Main Page|Something else]]\n\n[[Main Page|Something else]]\n" |
| 1523 |
}, |
| 1524 |
"Verify that displaytitle encodes & to & (T291985)": { |
| 1525 |
"metadata": "" |
| 1526 |
}, |
| 1527 |
"Verify that displaytitle encodes & to & (T291985)": { |
| 1528 |
"metadata": "" |
| 1529 |
}, |
| 1530 |
"Verify that displaytitle handles inline CSS styles (T28547) - accepted value": { |
| 1531 |
"metadata": "" |
| 1532 |
}, |
| 1533 |
"Verify that displaytitle handles inline CSS styles (T28547) - rejected value": { |
| 1534 |
"metadata": "" |
| 1535 |
}, |
| 1536 |
"Verify that displaytitle works (T24501) AllowDisplayTitle=false": { |
| 1537 |
"metadata": "" |
| 1538 |
}, |
| 1539 |
"Verify that displaytitle works (T24501) AllowDisplayTitle=false no DISPLAYTITLE": { |
| 1540 |
"metadata": "" |
| 1541 |
}, |
| 1542 |
"Verify that displaytitle works (T24501) RestrictDisplayTitle=false": { |
| 1543 |
"metadata": "" |
| 1544 |
}, |
| 1545 |
"Verify that displaytitle works (T24501) RestrictDisplayTitle=true matching": { |
| 1546 |
"metadata": "" |
| 1547 |
}, |
| 1548 |
"Verify that displaytitle works (T24501) RestrictDisplayTitle=true mismatch": { |
| 1549 |
"metadata": "" |
| 1550 |
}, |
| 1551 |
"Verify that displaytitle works (T24501) no displaytitle": { |
| 1552 |
"metadata": "" |
| 1553 |
}, |
| 1554 |
"Verify that without displaytitle the title encodes & to & (T291985)": { |
| 1555 |
"metadata": "" |
| 1556 |
}, |
| 1557 |
"WTS of an autolink surrounded by square brackets (T220018)": { |
| 1558 |
"html2wt": "[http://example.com<nowiki>]</nowiki>" |
| 1559 |
}, |
| 1560 |
"WTS of an external link surrounded by square brackets (T220018)": { |
| 1561 |
"html2wt": "[[http://example.com foo]]" |
| 1562 |
}, |
| 1563 |
"WTS of edited autolink surrounded by square brackets (T220018)": { |
| 1564 |
"wt2wt": "[http://example.com<nowiki>]</nowiki>", |
| 1565 |
"selser [manual]": "[http://example.com<nowiki>]</nowiki>" |
| 1566 |
}, |
| 1567 |
"WTS of edited external link surrounded by square brackets (T220018)": { |
| 1568 |
"wt2wt": "[[http://example.com foo]]", |
| 1569 |
"selser [manual]": "[[http://example.com foo]]" |
| 1570 |
}, |
| 1571 |
"anchorencode encodes like the TOC generator: (T20431)": { |
| 1572 |
"html2wt": "=== _ +:.3A%3A _ &&]] x ===\n{{anchorencode: _ +:.3A%3A _ &&]] x}}\n\n__NOEDITSECTION__\n", |
| 1573 |
"selser [2,2,3,0,0]": "19m5ghj\n\n===_ +:.3A%3A _ &&]] x===\n1n9wtpj\n\n\n__NOEDITSECTION__" |
| 1574 |
}, |
| 1575 |
"cats/langlinks: migrateTrailingSolTransparentLinks dom pass should not get tripped by comments and whitespace": { |
| 1576 |
"html2wt": "* a\n\n[[Category:Bar]]<!--boo1--> <!--boo2-->\n[[Category:Baz]]<!--boo3--> <!--boo4-->\n[[es:Foo]]<!--boo5--> <!--boo6-->" |
| 1577 |
}, |
| 1578 |
"div with illegal double attributes": { |
| 1579 |
"wt2wt": "<div id=\"b\">HTML rocks</div>", |
| 1580 |
"html2wt": "<div id=\"b\">HTML rocks</div>", |
| 1581 |
"selser [2]": "mh76bk<div id=\"a\" id=\"b\">HTML rocks</div>", |
| 1582 |
"selser [[4]]": "<div id=\"a\" id=\"b\">2q019h</div>", |
| 1583 |
"selser [[3]]": "<div id=\"a\" id=\"b\"></div>", |
| 1584 |
"selser [[2]]": "<div id=\"a\" id=\"b\">j6zotpHTML rocks</div>" |
| 1585 |
}, |
| 1586 |
"div with single-quoted attribute": { |
| 1587 |
"wt2wt": "<div id=\"rock\">HTML rocks</div>", |
| 1588 |
"html2wt": "<div id=\"rock\">HTML rocks</div>", |
| 1589 |
"selser [2]": "pky5rs<div id='rock'>HTML rocks</div>", |
| 1590 |
"selser [[2]]": "<div id='rock'>f3egylHTML rocks</div>", |
| 1591 |
"selser [[4]]": "<div id='rock'>ttkym7</div>", |
| 1592 |
"selser [[3]]": "<div id='rock'></div>" |
| 1593 |
}, |
| 1594 |
"div with unquoted attribute": { |
| 1595 |
"wt2wt": "<div id=\"rock\">HTML rocks</div>", |
| 1596 |
"html2wt": "<div id=\"rock\">HTML rocks</div>", |
| 1597 |
"selser [2]": "gfvz7s<div id=rock>HTML rocks</div>", |
| 1598 |
"selser [[4]]": "<div id=rock>1mp0zbb</div>", |
| 1599 |
"selser [[3]]": "<div id=rock></div>", |
| 1600 |
"selser [[2]]": "<div id=rock>1n6014eHTML rocks</div>" |
| 1601 |
}, |
| 1602 |
"message transform: magic variables": { |
| 1603 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,12,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,12,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"SITENAME\",\"function\":\"sitename\"},\"params\":{},\"i\":0}}]}'>MediaWiki</span></p>", |
| 1604 |
"html2html": "<p data-parsoid='{\"dsr\":[0,9,0,0]}'>MediaWiki</p>", |
| 1605 |
"html2wt": "MediaWiki" |
| 1606 |
}, |
| 1607 |
"message transform: should not transform wiki markup": { |
| 1608 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,8,0,0]}'><i data-parsoid='{\"dsr\":[0,8,2,2]}'>test</i></p>", |
| 1609 |
"html2html": "<p data-parsoid='{\"dsr\":[0,25,0,0]}'><span typeof=\"mw:Nowiki\" data-parsoid='{\"dsr\":[0,25,8,9]}'>''test''</span></p>", |
| 1610 |
"html2wt": "<nowiki>''test''</nowiki>" |
| 1611 |
}, |
| 1612 |
"multiple templates that are redirects": { |
| 1613 |
"metadata": "" |
| 1614 |
}, |
| 1615 |
"new support for bdi element (T33817)": { |
| 1616 |
"html2html": "<p data-parsoid='{\"dsr\":[0,193,0,0]}'>ולדימיר לנין (ברוסית: <bdi lang=\"ru\" data-parsoid='{\"stx\":\"html\",\"dsr\":[39,87,15,6]}'>Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי.</p>", |
| 1617 |
"html2wt": "ולדימיר לנין (ברוסית: <bdi lang=\"ru\">Владимир Ленин</bdi>, 24 באפריל 1870–22 בינואר 1924) הוא מנהיג פוליטי קומוניסטי רוסי." |
| 1618 |
}, |
| 1619 |
"percent-encoding and + signs in internal links (T28410)": { |
| 1620 |
"selser [[0,0,0,0,[3],2,[4],4,2,4,3,3,4,4,3,4,[[[4]]],2,0,0,4]]": "[[User:+%]] [[Page+title%]]\ng6ebew [[%+|102p4ly]]<nowiki/>x43yh1kpwnbz[[%+ ]]1iz2d212bu4rt1hl6hdav5u0kv[[File:%+abc%39|foo|[[bar]]]]164yade\n[[%33%45]] mdq65u", |
| 1621 |
"selser [[4,2,[4],2,[3],0,2,0,0,4,0,3,[4],2,1,0,0,4,0,0,2]]": "145pa6l129ts4i [[Page+title%|1wirx1k]]1gqpjm3\n40e2zd[[%+|%20]] [[%+ ]]15mcys[[%+r]][[%|1bzm99r]]11b6xgc [[+]] [[File:%+abc%39|foo|[[bar]]]]jk1r4l[[%33%45]] 1qjrzva[[%33%45+]]" |
| 1622 |
}, |
| 1623 |
"text with character entity: eacute": { |
| 1624 |
"html2wt": "I always thought é was a cute letter.\n" |
| 1625 |
}, |
| 1626 |
"{{#special:}} page name, known": { |
| 1627 |
"wt2html": "<p data-parsoid='{\"dsr\":[0,26,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,26,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:Recentchanges\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span></p>", |
| 1628 |
"html2html": "<p data-parsoid='{\"dsr\":[0,26,0,0]}'><span about=\"#mwt1\" typeof=\"mw:Transclusion\" data-parsoid='{\"pi\":[[]],\"dsr\":[0,26,null,null]}' data-mw='{\"parts\":[{\"template\":{\"target\":{\"wt\":\"#special:Recentchanges\",\"function\":\"special\"},\"params\":{},\"i\":0}}]}'>Parser function implementation for pf_special missing in Parsoid.</span></p>" |
| 1629 |
}, |
| 1630 |
"{{defaultsort}} should be location-independent (T353530)": { |
| 1631 |
"metadata": "cat=Foo sort=\ncat=Bat sort=" |
| 1632 |
} |
| 1633 |
} |