Module:siwa-noun/testcases

< Module:siwa-noun
Revision as of 14:09, 18 July 2021 by Sware (talk | contribs)
local tests = require('Module:UnitTests')
local m_noun = require('Module:siwa-noun')

function tests:check_output(term, expected, noresp)
	return tests:equals(
		term,
		m_noun.make_cases(),
		expected,
		{ show_difference = true }
	)
end

function tests:test_example()
	local list= {
		"sivi",	"[[Contionary:sivi]]\n[[Contionary:sỉd]]\n[[Contionary:sỉdia]]\n[[Contionary:sỉhta]]\n[[Contionary:sỉhka]]\n[[Contionary:sỉhma]]\n[[Contionary:sỉbma]], [[Contionary:sỉddįibma]]\n[[Contionary:sỉska]], [[Contionary:sỉddįiska]]"
	}
	self:iterate(list,"check_inflection")
end

return tests