MediaWiki  1.32.5
extensions/Cite/tests/parser/citeParserTests.txt File Reference

Functions

</p >< p >< br/></p > ! end ! test< ref > in a<!--comment--> ! wikitext Templating<!--< ref >{{simple template}}</ref > -->< references/> ! html< p > Templating</p >< p >< br/></p > ! end ! test<!--comment--> in a< ref > (bug 5384) !! wikitext Templating< ref >Text<!--comment- -></ref >< references/> !! html< p >Templating< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &#91
 
name blank defined multiple times with different content</span ></span ></li ></ol ></div > ! end ! test Ref names containing a number ! wikitext< ref name="test123test"> One</ref >< ref name="123test"> Two</ref >< ref name="test123"> Three</ref >< references/> ! html< p >< sup id="cite_ref-test123test_1-0" class="reference">< a href="#cite_note-test123test-1"> &< sup id="cite_ref-123test_2-0" class="reference">< a href="#cite_note-123test-2"> &< sup id="cite_ref-test123_3-0" class="reference">< a href="#cite_note-test123-3"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-test123test-1">< span class="mw-cite-backlink">< a href="#cite_ref-test123test_1-0"> ↑</a ></span >< span class="reference-text"> One</span ></li >< li id="cite_note-123test-2">< span class="mw-cite-backlink">< a href="#cite_ref-123test_2-0"> ↑</a ></span >< span class="reference-text"> Two</span ></li >< li id="cite_note-test123-3">< span class="mw-cite-backlink">< a href="#cite_ref-test123_3-0"> ↑</a ></span >< span class="reference-text"> Three</span ></li ></ol ></div > ! end ! test Erroneous refs ! wikitext< ref name="0"> Zero</ref >< ref > Also but differently (Normal ref)</ref >< ref/>< ref name ="cite_note-bar-2"><span class="mw-cite-backlink"><a href="#cite_ref-bar_2-0">↑</a></span> <span class="error mw-ext-cite-error" lang="en" dir="ltr">Cite error: Invalid <code>&lt
 

Variables

&</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Text</span ></li ></ol ></div > ! end ! test< references > after< gallery > &(bug 6164) !! wikitext< ref >one</ref >< gallery >Image</p >< ul class="gallery mw-gallery-traditional">< li class="gallerybox" style="width: 155px">< div style="width: 155px">< div class="thumb" style="width: 150px;">< div style="margin:68px auto;">< a href="/wiki/File:Foobar.jpg" class="image">< img alt="Foobar.jpg" src="http: <div class="gallerytext"></div></div></li></ul><div class="mw-references-wrap"><ol class="references"><li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1"> ↑</a></span><span class="reference-text"> one</span></li></ol></div> ! end ! test
 
notes< references group="注"/> ! html< p > AAA< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &</p >< dl >< dt > refs</dt ></dl >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> ref a</span ></li >< li id="cite_note-3">< span class="mw-cite-backlink">< a href="#cite_ref-3"> ↑</a ></span >< span class="reference-text"> ref c</span ></li ></ol ></div >< dl >< dt > notes</dt ></dl >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-2">< span class="mw-cite-backlink">< a href="#cite_ref-2"> ↑</a ></span >< span class="reference-text"> note b</span ></li ></ol ></div > ! end ! test< ref > defined in< references > ! wikitext< ref name="foo"/>< references >< ref name="foo"> BAR</ref ></references > ! html< p >< sup id="cite_ref-foo_1-0" class="reference">< a href="#cite_note-foo-1"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-foo-1">< span class="mw-cite-backlink">< a href="#cite_ref-foo_1-0"> ↑</a ></span >< span class="reference-text"> BAR</span ></li ></ol ></div > ! end ! test< ref > defined in< references > called with ! wikitext< ref name="foo"/>
 
no text was provided for refs named< code > blankwithnoreference</code ></span ></li ></ol ></div > ! end ! test with< references/> in group ! wikitext Wikipedia rocks< ref > Proceeds of vol XXI</ref > Wikipedia rocks< ref group=note > Proceeds of vol XXI</ref >< references/>< references group=note/> ! html< p > Wikipedia rocks< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &Wikipedia rocks< sup id="cite_ref-2" class="reference">< a href="#cite_note-2"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-2">< span class="mw-cite-backlink">< a href="#cite_ref-2"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div > ! end ! test with< references/> in with groupname in Chinese ! wikitext AAA< ref group="参"> ref a</ref > BBB< ref group="注"> note b</ref > CCC< ref group="参"> ref c</ref >
 
name blank defined multiple times with different content</span ></span ></li ></ol ></div > ! end ! test Regression sanity check
 
&</p >< p >< sup id="cite_ref-blank_1-1" class="reference">< a href="#cite_note-blank-1"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-blank-1">< span class="mw-cite-backlink"> ↑< sup >< a href="#cite_ref-blank_1-0"></a ></sup >< sup >< a href="#cite_ref-blank_1-1"></a ></sup ></span >< span class="reference-text">< span class="error mw-ext-cite-error" lang="en" dir="ltr"> Cite error
 
no text was provided for refs named< code > blankwithnoreference</code ></span ></li ></ol ></div > ! end ! test with< references/> in group ! wikitext Wikipedia rocks< ref > Proceeds of vol XXI</ref > Wikipedia rocks< ref group=note > Proceeds of vol XXI</ref >< references/>< references group=note/> ! html< p > Wikipedia rocks< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &Wikipedia rocks< sup id="cite_ref-2" class="reference">< a href="#cite_note-2"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-2">< span class="mw-cite-backlink">< a href="#cite_ref-2"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div > ! end ! test with< references/> in group
 
&</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> A< i > simple</i > template</span ></li ></ol ></div > ! end ! test< ref > with a< nowiki > ! wikitext Templating< ref >< nowiki > &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> ref & gt
 
</code > tag with name unused defined in< code > & lt
 
</code > has no name attribute</span ></p > ! end ! article MediaWiki
 
 refs< references group="参"/>
 
&</p >< p >< sup id="cite_ref-blank_1-1" class="reference">< a href="#cite_note-blank-1"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-blank-1">< span class="mw-cite-backlink"> ↑< sup >< a href="#cite_ref-blank_1-0"></a ></sup >< sup >< a href="#cite_ref-blank_1-1"></a ></sup ></span >< span class="reference-text"> content</span ></li ></ol ></div > ! end ! test Blank ref followed by ref with content ! wikitext< ref name="blank"/>< ref name="blank"> content</ref >< references/> ! html< p >< sup id="cite_ref-blank_1-0" class="reference">< a href="#cite_note-blank-1"> &</p >< p >< sup id="cite_ref-blank_1-1" class="reference">< a href="#cite_note-blank-1"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-blank-1">< span class="mw-cite-backlink"> ↑< sup >< a href="#cite_ref-blank_1-0"></a ></sup >< sup >< a href="#cite_ref-blank_1-1"></a ></sup ></span >< span class="reference-text"> content</span ></li ></ol ></div > ! end ! test Regression
 
! hooks ref references ! endhooks ! article no< references/> ! wikitext Wikipedia rocks< ref > Proceeds of Rockology
 
! hooks ref references ! endhooks ! article no< references/> ! wikitext Wikipedia rocks< ref > Proceeds of vol XXI</ref > ! html Wikipedia rocks< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div > ! end ! test Simple< ref >
 
</codetag
 
! hooks ref references ! endhooks ! article Template
 
name blank defined multiple times with different content</span ></span ></li ></ol ></div > ! end ! test Ref names containing a number ! wikitext< ref name="test123test"> One</ref >< ref name="123test"> Two</ref >< ref name="test123"> Three</ref >< references/> ! html< p >< sup id="cite_ref-test123test_1-0" class="reference">< a href="#cite_note-test123test-1"> &< sup id="cite_ref-123test_2-0" class="reference">< a href="#cite_note-123test-2"> &< sup id="cite_ref-test123_3-0" class="reference">< a href="#cite_note-test123-3"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-test123test-1">< span class="mw-cite-backlink">< a href="#cite_ref-test123test_1-0"> ↑</a ></span >< span class="reference-text"> One</span ></li >< li id="cite_note-123test-2">< span class="mw-cite-backlink">< a href="#cite_ref-123test_2-0"> ↑</a ></span >< span class="reference-text"> Two</span ></li >< li id="cite_note-test123-3">< span class="mw-cite-backlink">< a href="#cite_ref-test123_3-0"> ↑</a ></span >< span class="reference-text"> Three</span ></li ></ol ></div > ! end ! test Erroneous refs ! wikitext< ref name="0"> Zero</ref >< ref > Also zero
 

Function Documentation

◆ a< ref >()

</p><p><br /></p> ! end ! test<ref> in a<!--comment--> ! wikitext Templating<!--<ref>{{simple template}}</ref>--><references/> ! html<p> Templating</p><p><br /></p> ! end ! test<!--comment--> in a< ref > ( bug  5384) -> </ref >< references/> !! html< p >Templating< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &#91

◆ differently()

</code > tag</span ></p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Also but differently ( Normal  ref) ="cite_note-bar-2"><span class="mw-cite-backlink"><a href="#cite_ref-bar_2-0">↑</a></span> <span class="error mw-ext-cite-error" lang="en" dir="ltr">Cite error: Invalid <code>&lt

Variable Documentation

◆ ! test

&< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> elite</span ></li ></ol ></div > ! end ! test
Initial value:
{{REVISIONID}} on page with <ref> (bug 6299)
!! wikitext
{{REVISIONID}}<ref>elite</ref>
!! html
1337<sup id="cite_ref-1" class="reference"><a href="#cite_note-1">&#91

Definition at line 154 of file citeParserTests.txt.

◆ ! wikitext< ref name="foo"/>

notes<references group="注" /> ! html<p> AAA<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"> &</p><dl><dt> refs</dt></dl><div class="mw-references-wrap"><ol class="references"><li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1"> ↑</a></span><span class="reference-text"> ref a</span></li><li id="cite_note-3"><span class="mw-cite-backlink"><a href="#cite_ref-3"> ↑</a></span><span class="reference-text"> ref c</span></li></ol></div><dl><dt> notes</dt></dl><div class="mw-references-wrap"><ol class="references"><li id="cite_note-2"><span class="mw-cite-backlink"><a href="#cite_ref-2"> ↑</a></span><span class="reference-text"> note b</span></li></ol></div> ! end ! test<ref> defined in<references> ! wikitext<ref name="foo"/><references><ref name="foo"> BAR</ref></references> ! html<p><sup id="cite_ref-foo_1-0" class="reference"><a href="#cite_note-foo-1"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-foo-1"><span class="mw-cite-backlink"><a href="#cite_ref-foo_1-0"> ↑</a></span><span class="reference-text"> BAR</span></li></ol></div> ! end ! test<ref> defined in<references> called with ! wikitext< ref name="foo"/>
Initial value:
{{#tag:references|
<ref name="foo">BAR</ref>
}}
!! html
<p><sup id="cite_ref-foo_1-0" class="reference"><a href="#cite_note-foo-1">&#91

Definition at line 385 of file citeParserTests.txt.

References name, and tag.

◆ c</ref >

no text was provided for refs named<code> blankwithnoreference</code></span></li></ol></div> ! end ! test with<references/> in group ! wikitext Wikipedia rocks<ref> Proceeds of vol XXI</ref> Wikipedia rocks<ref group=note> Proceeds of vol XXI</ref><references/><references group=note/> ! html<p> Wikipedia rocks<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"> & Wikipedia rocks<sup id="cite_ref-2" class="reference"><a href="#cite_note-2"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1"> ↑</a></span><span class="reference-text"> Proceeds of vol XXI</span></li></ol></div><div class="mw-references-wrap"><ol class="references"><li id="cite_note-2"><span class="mw-cite-backlink"><a href="#cite_ref-2"> ↑</a></span><span class="reference-text"> Proceeds of vol XXI</span></li></ol></div> ! end ! test with<references/> in with groupname in Chinese ! wikitext AAA<ref group="参"> ref a</ref> BBB<ref group="注"> note b</ref> CCC<ref group="参"> ref c</ref >

Definition at line 312 of file citeParserTests.txt.

◆ check

</code> has no name attribute</span></p> ! end ! article vol XXI</ref><references group="klingon"/> ! html<p> Wikipedia rocks<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1"> ↑</a></span><span class="reference-text"> Proceeds of vol XXI</span></li></ol></div> ! end ! test Bug regression check

Definition at line 240 of file citeParserTests.txt.

◆ error

</code> has conflicting group attribute</span><br /><span class="error mw-ext-cite-error" lang="en" dir="ltr"> Cite error

Definition at line 225 of file citeParserTests.txt.

◆ group

no text was provided for refs named<code> blankwithnoreference</code></span></li></ol></div> ! end ! test with<references/> in group ! wikitext Wikipedia rocks<ref> Proceeds of vol XXI</ref> Wikipedia rocks<ref group=note> Proceeds of vol XXI</ref><references/><references group=note/> ! html<p> Wikipedia rocks<sup id="cite_ref-1" class="reference"><a href="#cite_note-1"> & Wikipedia rocks<sup id="cite_ref-2" class="reference"><a href="#cite_note-2"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-1"><span class="mw-cite-backlink"><a href="#cite_ref-1"> ↑</a></span><span class="reference-text"> Proceeds of vol XXI</span></li></ol></div><div class="mw-references-wrap"><ol class="references"><li id="cite_note-2"><span class="mw-cite-backlink"><a href="#cite_ref-2"> ↑</a></span><span class="reference-text"> Proceeds of vol XXI</span></li></ol></div> ! end ! test with<references/> in group

◆ gt

a & gt
Initial value:
{{simple template}}</span>
</li>
</ol></div>
!! end
!! test
<ref> in a <nowiki>
!! wikitext
Templating<nowiki><ref>{{simple template}}</ref></nowiki>
<references/>
!! html
<p>Templating&lt

Definition at line 81 of file citeParserTests.txt.

◆ lt

</code> tag defined in<code>& lt

Definition at line 416 of file citeParserTests.txt.

◆ MediaWiki

</code> has no name attribute</span></p> ! end ! article MediaWiki

Definition at line 431 of file citeParserTests.txt.

◆ refs< references group="参"/>

refs< references group="参"/>

Definition at line 342 of file citeParserTests.txt.

◆ Regression

&</p><p><sup id="cite_ref-blank_1-1" class="reference"><a href="#cite_note-blank-1"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-blank-1"><span class="mw-cite-backlink"> ↑<sup><a href="#cite_ref-blank_1-0"></a></sup><sup><a href="#cite_ref-blank_1-1"></a></sup></span><span class="reference-text"> content</span></li></ol></div> ! end ! test Blank ref followed by ref with content ! wikitext<ref name="blank"/><ref name="blank"> content</ref><references/> ! html<p><sup id="cite_ref-blank_1-0" class="reference"><a href="#cite_note-blank-1"> &</p><p><sup id="cite_ref-blank_1-1" class="reference"><a href="#cite_note-blank-1"> &</p><div class="mw-references-wrap"><ol class="references"><li id="cite_note-blank-1"><span class="mw-cite-backlink"> ↑<sup><a href="#cite_ref-blank_1-0"></a></sup><sup><a href="#cite_ref-blank_1-1"></a></sup></span><span class="reference-text"> content</span></li></ol></div> ! end ! test Regression

Definition at line 221 of file citeParserTests.txt.

◆ Rockology

</code > has no name attribute</span ></p > ! end ! article vol XXI</ref >< references group="klingon"/> ! html< p > Wikipedia rocks< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Proceeds of Rockology

Definition at line 20 of file citeParserTests.txt.

◆ Simple< ref >

no text was provided for refs named< code > blankwithnoreference</code ></span ></li ></ol ></div > ! end ! test with< references/> in group ! wikitext Wikipedia rocks< ref > Proceeds of vol XXI</ref > Wikipedia rocks< ref group=note > Proceeds of vol XXI</ref >< references/>< references group=note/> ! html< p > Wikipedia rocks< sup id="cite_ref-1" class="reference">< a href="#cite_note-1"> &Wikipedia rocks< sup id="cite_ref-2" class="reference">< a href="#cite_note-2"> &</p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-2">< span class="mw-cite-backlink">< a href="#cite_ref-2"> ↑</a ></span >< span class="reference-text"> Proceeds of vol XXI</span ></li ></ol ></div > ! end ! test Simple< ref >

Definition at line 20 of file citeParserTests.txt.

◆ tag

◆ Template

Foo and Baz ! endarticle ! article Template

Definition at line 20 of file citeParserTests.txt.

◆ zero

</code > tag</span ></p >< div class="mw-references-wrap">< ol class="references">< li id="cite_note-1">< span class="mw-cite-backlink">< a href="#cite_ref-1"> ↑</a ></span >< span class="reference-text"> Also zero

Definition at line 279 of file citeParserTests.txt.

Referenced by XCFHandler::getXCFMetaData().

a
</source > ! result< div class="mw-highlight mw-content-ltr" dir="ltr">< pre >< span ></span >< span class="kd"> var</span >< span class="nx"> a</span >< span class="p"></span ></pre ></div > ! end ! test Multiline< source/> in lists !input *< source > a b</source > *foo< source > a b</source > ! html< ul >< li >< div class="mw-highlight mw-content-ltr" dir="ltr">< pre > a b</pre ></div ></li ></ul >< ul >< li > foo< div class="mw-highlight mw-content-ltr" dir="ltr">< pre > a b</pre ></div ></li ></ul > ! html tidy< ul >< li >< div class="mw-highlight mw-content-ltr" dir="ltr">< pre > a b</pre ></div ></li ></ul >< ul >< li > foo< div class="mw-highlight mw-content-ltr" dir="ltr">< pre > a b</pre ></div ></li ></ul > ! end ! test Custom attributes !input< source lang="javascript" id="foo" class="bar" dir="rtl" style="font-size: larger;"> var a
Definition: parserTests.txt:89
page
target page
Definition: All_system_messages.txt:1267
name
and how to run hooks for an and one after Each event has a name
Definition: hooks.txt:6
lt
</code > tag with name unused defined in< code > & lt
Definition: citeParserTests.txt:416
simple
and how to run hooks for an and one after Each event has a preferably in CamelCase For ArticleDelete hook A clump of code and data that should be run when an event happens This can be either a function and a chunk of or an object and a method hook function The function part of a third party developers and administrators to define code that will be run at certain points in the mainline and to modify the data run by that mainline code Hooks can keep mainline code simple
Definition: hooks.txt:23
in
null for the wiki Added in
Definition: hooks.txt:1627
div
div
Definition: parserTests.txt:6868
on
Using a hook running we can avoid having all this option specific stuff in our mainline code Using the function We ve cleaned up the code here by removing clumps of infrequently used code and moving them off somewhere else It s much easier for someone working with this code to see what s _really_ going on
Definition: hooks.txt:77
captcha-old.p
p
Definition: captcha-old.py:275
tag
</code > tag
Definition: citeParserTests.txt:225
href
shown</td >< td > a href
Definition: All_system_messages.txt:2667