Module:Deva-Newa-translit/testcases

-- Unit tests for Module:Deva-Newa-translit. Refresh page to run tests. local tests = require('Module:UnitTests') local transliterate = require('Module:Deva-Newa-translit').tr

local function tag(text) return ' ' .. text .. ' ' end

local options = { display = tag } --TO DO function tests:do_test_translit(deva, newa, xlit) self:equals(' ' .. deva .. ' ',		transliterate(deva, 'new', 'Deva'),		newa,		options) end

function tests:test_translit_newa local examples = { { 'न्ह', '𑐤' }, { 'ङ्ह', '𑐓' }, { 'र्ह', '𑐭' }, { 'ल्ह', '𑐯' }, { 'म्ह', '𑐪' }, { 'ञ्ह', '𑐙' }, }	self:iterate(examples, 'do_test_translit') end return tests