Module:ISO 639 name/testcases/ISO 639-2 name from code

From WikiCigar
< Module:ISO 639 name‎ | testcases
Revision as of 06:26, 6 October 2020 by en>Gonnym (Gonnym moved page Module:ISO 639 name/testcases/ISO 639-2 code to name to Module:ISO 639 name/testcases/ISO 639-2 name from code without leaving a redirect)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Documentation for this module may be created at Module:ISO 639 name/testcases/ISO 639-2 name from code/doc

local p = require("Module:UnitTests")

local function main(self, data, iso_number)
	local language_list = mw.loadData(data)
	require("Module:Lang/documentor tool").testcases_iso_code_to_name(self, {language_list = language_list, iso_number = iso_number})
end


function p:test_iso_639_2_code_to_name()
	main(self, "Module:Language/data/ISO 639-2", "2")
end


function p:test_iso_639_2B_code_to_name()
	main(self, "Module:Language/data/ISO 639-2B", "2B")
end

return p