Jump to content

Module:Template parameter value/testcases

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Aidan9382 (talk | contribs) at 11:16, 23 February 2023 (nice typo (+ proper tests)). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
--Go to the talk page to see the results of the tests. See [[Template:Template parameter value/testpage]] for the content used in testing
local p = require('Module:UnitTests')
local TestPage = "Template:Template parameter value/testpage"

function p:test_TemplateEntry()
	self:preprocess_equals_sandbox_many('{{#invoke:Template parameter value', 'main', {
		{TestPage.."|Template3||_id", "1"},
		{TestPage.."|Template1||_id", "2"},
		{TestPage.."|Template2||_id", "3"},
	}, {nowiki=1})
end

return p