Jump to content

Module:ArgTest

From The Secret Wiki
Revision as of 21:59, 10 October 2025 by Burnstyle (talk | contribs) (Created page with "local p = {} function p.main( frame ) -- This line uses the module we are testing local args = require('Module:Arguments').getArgs(frame) -- Check for a parameter named 'text' and return its value if args.text then return "SUCCESS! Module:Arguments is working. It received the message: '" .. args.text .. "'" else return "FAILURE. Module:Arguments is NOT working. It received no data." end end return p")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Documentation for this module may be created at Module:ArgTest/doc

local p = {}

function p.main( frame )
    -- This line uses the module we are testing
    local args = require('Module:Arguments').getArgs(frame)

    -- Check for a parameter named 'text' and return its value
    if args.text then
        return "SUCCESS! Module:Arguments is working. It received the message: '" .. args.text .. "'"
    else
        return "FAILURE. Module:Arguments is NOT working. It received no data."
    end
end

return p