Module:Sandbox/Nyoron/anyToString/testcases explained

local p =

local m = require('Module:Sandbox/Nyoron/anyToString')

-- Test datalocal var_nil = nillocal var_boolean_true = truelocal var_boolean_false = falselocal var_string = "string-text"local var_number = 1234.567local var_function1 = function return "return of function1" endlocal var_function2 = function return "return of function2" endlocal var_function3 = function return "return of function3" endlocal var_function4 = function return "return of function4" end

local var_table8 = local var_table7 = local var_table6 = local var_table5 = local var_table4 =

local var_table3 =

local var_table2 =

local var_table1 =

p.run_tests = function(frame) local result = result = "

"
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_nil))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_boolean_true))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_boolean_false))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_string))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_number))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_function))

    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_table1, false, 0, 4))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(var_table1, true, 4, 4))
    result = mw.ustring.format("%s%s<br/>",result,mw.dumpObject(var_table1))

    -- https://en.wikipedia.org/wiki/MediaWiki:Titleblacklist
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(mw.ext.TitleBlacklist.test('move','Module:Sandbox/にょろん/REVISIONUSER')))
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(mw.ext.TitleBlacklist.test('move','Module:Sandbox/にょろん/anyToString')))
    -- Regarding new-account, see https://meta.wikimedia.org/wiki/Title_blacklist
    result = mw.ustring.format("%s%s<br/>",result,m.anyToString(mw.ext.TitleBlacklist.test('new-account','AIDS12349876')))

	result = result .. "
" return resultend

return p