Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

Jump to content

Module:DartsRankings/testcases

From Wikipedia, the free encyclopedia
local p = require('Module:UnitTests')

function p:test_playerLink()
    self:preprocess_equals_sandbox_many('{{#invoke:DartsRankings', 'playerLink', {
        {'PDC Rankings|Michael van Gerwen|flag = ', '<span class="nowrap"><span class="flagicon" style="display:inline-block;width:25px;text-align:left">[[File:Flag of the Netherlands.svg|23x15px|border|link=Netherlands|alt=]]</span>&nbsp;</span><span data-sort-value="Gerwen, Michael van"><span class="vcard"><span class="fn">[[Michael van Gerwen]]</span></span></span>' },
    	{'PDC Rankings|Michäël VaN GeRWÈn|flag = ', '<span class="nowrap"><span class="flagicon" style="display:inline-block;width:25px;text-align:left">[[File:Flag of the Netherlands.svg|23x15px|border|link=Netherlands|alt=]]</span>&nbsp;</span><span data-sort-value="Gerwen, Michael van"><span class="vcard"><span class="fn">[[Michael van Gerwen]]</span></span></span>' },
    	{'PDC Rankings|Joe Bloggs|flag = ', '<span class="nowrap"><span class="flagicon" style="display:inline-block;width:27px;text-align:left">[[File:Flag placeholder.svg|25x17px|link=|alt=]]</span>&nbsp;</span>[[Joe Bloggs]][[Category:Pages using DartsRankings with missing player data|Joe Bloggs]]'},
        {'PDC Rankings|Michael van Gerwen|flag = UK', '<span class="nowrap"><span class="flagicon" style="display:inline-block;width:25px;text-align:left">[[File:Flag of the United Kingdom.svg|23x15px|border|link=United Kingdom|alt=]]</span>&nbsp;</span><span data-sort-value="Gerwen, Michael van"><span class="vcard"><span class="fn">[[Michael van Gerwen]]</span></span></span>'}
    }, {nowiki=1})
end

return p