Module:Sind-translit/testcases
Documentation for this module may be created at Module:Sind-translit/testcases/doc
-- Unit tests for [[Module:Sind-translit]]. Refresh page to run tests.
local tests = require('Module:UnitTests')
local sind_translit = require('Module:Sind-translit')
--TO DO
function tests:do_test_translit(sind, roman, xlit)
self:equals('<span class="Sind" lang="sd">[[' .. sind .. '#Sind|' .. sind .. ']]</span>', sind_translit.tr(sind, 'sd', 'Sind'), roman)
end
function tests:test_translit_sind()
local examples = {
{ '๐๐ก๐๐๐ข', 'sindhฤซ' },
{ '๐๐ก๐๐ช๐๐ข', 'sindhฤซ' },
{ '๐๐ ๐ฟ๐ง', 'bhฤแน
o' },
{ '๐๐ ๐๐ฃ', 'mฤlu' },
{ '๐๐ฅ๐บ๐ง', 'jeko' },
{ '๐๐ฅ๐', 'mแบฝ' },
{ '๐ท๐', 'aอ i' },
{ '๐ป๐ฉ๐๐', 'xabara' },
}
self:iterate(examples, 'do_test_translit')
end
return tests