Module:dv-translit/testcases
Appearance
- The following documentation is located at Module:dv-translit/testcases/documentation. [edit] Categories were auto-generated by Module:module categorization. [edit]
- Useful links: root page • root page’s subpages • links • transclusions • tested module • sandbox
This is the unit-testing module for Module:dv-translit.
1 of 20 tests failed. (refresh)
Text | Expected | Actual | Differs at | |
---|---|---|---|---|
ކަރުދާސް | karudās | karudās | ||
އޮމާމަސް | omāmas | omāmas | ||
ފޮތް | fot̊ | fot̊ | ||
ގައްޤެ | gaqqe | gaqqe | ||
ރަށް | raṣ̊ | raṣ̊ | ||
ނަން | nam̊ | nan̊ | 3 | |
ފަން | fan̊ | fan̊ | ||
ރުއް | ruk̊ | ruk̊ | ||
އަނބި | aᵐbi | aᵐbi | ||
ޅޮނގު | ḷoⁿgu | ḷoⁿgu | ||
ހަނޑު | haⁿḍu | haⁿḍu | ||
ހަނދު | haⁿdu | haⁿdu | ||
ފިއްޔެއް | fiyyek̊ | fiyyek̊ | ||
އަތްނބެއް | at̊ᵐbek̊ | at̊ᵐbek̊ | ||
ލޯބި | lōbi | lōbi | ||
ލޯތްބެއް | lōt̊bek̊ | lōt̊bek̊ | ||
ކަށި | kaṣi | kaṣi | ||
ކައްޓެއް | kaṭṭek̊ | kaṭṭek̊ | ||
ހިނދުރި | hiⁿduri | hiⁿduri | ||
ވައްދަ | vadda | vadda |
-- Unit tests for [[Module:dv-translit]]. Refresh page to run tests.
local tests = require('Module:UnitTests')
local dv_translit = require('Module:dv-translit')
function tests:check_translit(Thaa, roman)
self:equals('<span class="Thaa" lang="dv">[[' .. Thaa .. '#Dhivehi|' .. Thaa .. ']]</span>', dv_translit.tr(Thaa, 'dv', 'Thaa'), roman)
end
function tests:test_translit_dhivehi()
self:iterate(
{
{ 'ކަރުދާސް', 'karudās' },
{ 'އޮމާމަސް', 'omāmas' },
{ 'ފޮތް', 'fot̊' },
{ 'ގައްޤެ', 'gaqqe' },
{ 'ރަށް', 'raṣ̊' },
{ 'ނަން', 'nam̊' },
{ 'ފަން', 'fan̊' },
{ 'ރުއް', 'ruk̊' },
{ 'އަނބި', 'aᵐbi' },
{ 'ޅޮނގު', 'ḷoⁿgu' },
{ 'ހަނޑު', 'haⁿḍu' },
{ 'ހަނދު', 'haⁿdu' },
{ 'ފިއްޔެއް', 'fiyyek̊' },
{ 'އަތްނބެއް', 'at̊ᵐbek̊' },
{ 'ލޯބި', 'lōbi' },
{ 'ލޯތްބެއް', 'lōt̊bek̊' },
{ 'ކަށި', 'kaṣi' },
{ 'ކައްޓެއް', 'kaṭṭek̊' },
{ 'ހިނދުރި', 'hiⁿduri' },
{ 'ވައްދަ', 'vadda' }
},
"check_translit"
)
end
return tests