r21833 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r21832‎ | r21833 | r21834 >
Date:17:49, 3 May 2007
Author:hashar
Status:old
Tags:
Comment:
Parser test for bug #6204 : TOC not properly rendered when using $wgMaxTocLevel
Modified paths:
  • /trunk/phase3/maintenance/parserTests.txt (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/parserTests.txt
@@ -3408,6 +3408,42 @@
34093409 !! end
34103410
34113411 !! test
 3412+TOC with wgMaxTocLevel=3 (bug 6204)
 3413+!! options
 3414+wgMaxTocLevel=3
 3415+!! input
 3416+== title 1 ==
 3417+=== title 1.1 ===
 3418+==== title 1.1.1 ====
 3419+=== title 1.2 ===
 3420+== title 2 ==
 3421+=== title 2.1 ===
 3422+!! result
 3423+<table id="toc" class="toc" summary="Contents"><tr><td><div id="toctitle"><h2>Contents</h2></div>
 3424+<ul>
 3425+<li class="toclevel-1"><a href="#title_1"><span class="tocnumber">1</span> <span class="toctext">title 1</span></a>
 3426+<ul>
 3427+<li class="toclevel-2"><a href="#title_1.1"><span class="tocnumber">1.1</span> <span class="toctext">title 1.1</span></a></li>
 3428+<li class="toclevel-2"><a href="#title_1.2"><span class="tocnumber">1.2</span> <span class="toctext">title 1.2</span></a></li>
 3429+</ul>
 3430+</li>
 3431+<li class="toclevel-1"><a href="#title_2"><span class="tocnumber">2</span> <span class="toctext">title 2</span></a>
 3432+<ul>
 3433+<li class="toclevel-2"><a href="#title_2.1"><span class="tocnumber">2.1</span> <span class="toctext">title 2.1</span></a></li>
 3434+</ul>
 3435+</li>
 3436+</ul>
 3437+</td></tr></table><script type="text/javascript"> if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); } </script>
 3438+<a name="title_1"></a><h2><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=1" title="Edit section: title 1">edit</a>]</span> <span class="mw-headline"> title 1 </span></h2>
 3439+<a name="title_1.1"></a><h3><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=2" title="Edit section: title 1.1">edit</a>]</span> <span class="mw-headline"> title 1.1 </span></h3>
 3440+<a name="title_1.1.1"></a><h4><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=3" title="Edit section: title 1.1.1">edit</a>]</span> <span class="mw-headline"> title 1.1.1 </span></h4>
 3441+<a name="title_1.2"></a><h3><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=4" title="Edit section: title 1.2">edit</a>]</span> <span class="mw-headline"> title 1.2 </span></h3>
 3442+<a name="title_2"></a><h2><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=5" title="Edit section: title 2">edit</a>]</span> <span class="mw-headline"> title 2 </span></h2>
 3443+<a name="title_2.1"></a><h3><span class="editsection">[<a href="https://www.mediawiki.org/index.php?title=Parser_test&amp;action=edit&amp;section=6" title="Edit section: title 2.1">edit</a>]</span> <span class="mw-headline"> title 2.1 </span></h3>
 3444+
 3445+!! end
 3446+
 3447+!! test
34123448 Resolving duplicate section names
34133449 !! input
34143450 == Foo bar ==

Follow-up revisions

RevisionCommit summaryAuthorDate
r25291Revert r25260; breaks several parser tests cases, seems to be borking up sect...brion16:01, 29 August 2007
r25303Merged revisions 25215-25302 via svnmerge from...david07:10, 30 August 2007
r38208Revert r38196, r38204 -- "(bugs 6089, 13079) Show edit section links for tran...brion23:56, 29 July 2008

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r21725* (bug 6204) Fixes for indentation with $wgMaxTocLevel:...brion19:51, 30 April 2007
r21829Revert r21725 (bug 6204) due to regressions (bug 9764). Will leave it to be w...brion17:14, 3 May 2007