Module:evn-translit/testcases

local tests = require("Module:UnitTests") local evn_translit = require("Module:evn-translit")

local compose = mw.ustring.toNFC

function tests:check_translit(Cyrl, Latn) self:equals(		(' %s '):format(Cyrl, Cyrl),		compose(evn_translit.tr(Cyrl, 'evn', 'Cyrl')),		compose(Latn)) end

function tests:test_translit self:check_translit("тэкэ̄ты̄мӣ", "təkə̄tīmī") self:check_translit("тэгэен", "təgəjen") self:check_translit("тыеденэ", "tijeʒenə") self:check_translit("надан-дя̄гӣ", "nadan-ʒāgī") self:check_translit("мушняла̄бӯн", "muşņalābūn") self:check_translit("саӈняпчамӣ", "saŋņapçamī") self:check_translit("эӣмкӯн", "əjīmkūn") self:check_translit("эюргэ", "əjurgə") self:check_translit("дё̄нчамӣ", "ʒōnçamī") self:check_translit("тырганӣ", "tirgaņī") end

return tests