Module:WikiProject assessment progression/testcases

This is an old revision of this page, as edited by Sasuke Sarutobi (talk | contribs) at 23:23, 3 December 2020 (Changing assertSameType to wrap assertEquals). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
-- Unit tests for [[Module:WikiProject assessment progression]]. Click talk page to run tests.
local myModule = require('Module:WikiProject assessment progression')
local ScribuntoUnit = require('Module:ScribuntoUnit')
local suite = ScribuntoUnit:new()

function suite:assertSameType( expectedType, functionName )
	local outputType = type(functionName)
	self:assertEquals( expectedType , outputType )
end

-- Example unit test.
function suite:test_number_is_number()
	self:assertSameType( 'number' , 10 )
end

return suite