Module:cu-pronunciation/testcases

local tests = require('Module:UnitTests') local m_IPA = require('Module:cu-pronunciation')

local OCS = require('Module:languages').getByCode("cu") local Cyrillic = require('Module:scripts').getByCode("Cyrl")

local function link(term) return require("Module:links").full_link{ term = term, lang = OCS, sc = Cyrillic} end

local function tag_IPA(IPA) return ' ' .. IPA .. ' ' end

function tests:check_output(term, expected) tests:equals(		term,		m_IPA.toIPA(term),		expected,		{ display = tag_IPA }	) end

function tests:test_all list = { { "пѣти", "pæː.t̪iː"}, { "кѫ̏ща", "kɔ̃ꜜɔ̃.ʃtʲæː"}, { "Ꙁеѵсъ", "z̪ɛ̠.ʋs̪ə̆"}, { "Сѵрий", "s̪iː.ɾ̪iː.jɪ̆"}, { "ю̏гъ", "jʉꜜʉ.ɡə̆"}, {"ѣ̀сти", "jæꜛæ.s̪t̪iː"}, { "междоу̀", "mɛ̠.ʒdʲʉꜛʉ"}, { "съ́ѭꙁъ", "s̪ʊ.jɞ̃.z̪ə̆"}, { "ть̏нъкъ", "t̪ɪꜜ.n̪ʊ.kə̆"}, { "грь̏къ", "ɡr̩ꜜ.kə̆"}, { "влъ̏къ", "ʋɫ̩ꜜ.kə̆"}, { "чаꙗ̀ньѥ", "t͡ʃæː.jæꜛæ.n̪i.jɛ̠"}, { "мо̏р҄є", "mɔ̟ꜜ.ɾ̟ɛ̠"}, { "чрѣ̏шьнꙗ", "t͡ʃɾ̪æꜜæ.ʃɪ̆.ɲ̟æː"}, { "ꙁємлꙗ̏", "z̪ɛ̠.mʎ̟æꜜæ"}, { "прѣль̏стьнъ", "pɾ̪æː.l̪ɪꜜ.s̪t̪ɪ.n̪ə̆"}, { "хѣръ", "ɕæː.ɾ̪ə̆"}, }	self:iterate(list, "check_output") end return tests