Jump to content

Module:Ahom-translit/testcases

From Wiktionary, the free dictionary

1 of 2 tests failed. (refresh)

TextExpectedActual
test_translit:
Passed𑜁𑜨𑜧khowkhow
Failed𑜁𑜦𑜡khōkhoo

local tests = require("Module:UnitTests")
local transliterate = require("Module:Ahom-translit").tr

local function tag(text)
	return '<span class="Ahom">' .. text .. '</span>'
end

function tests:check(example, expected)
	return self:equals(
		tag(example),
		expected,
		transliterate(example)
	)
end

function tests:test_translit()
	local examples = {
		{ "𑜁𑜨𑜧", "khow" },
		{ "𑜁𑜦𑜡", "khoo" },
	}
	
	tests:iterate(examples, "check")
end

return tests