Module:Devmodule/testcases

-- Unit tests. Click talk page to run tests. local p ={ main={ -- function name options={nowiki=true}, tests = { preprocess_equals_many ={ {'#mod=if|test1|test2|test3', 'test2'}, {'#mod=if||test2|test3', 'test3'}, {'#mod=autochangecat|test2|test3|days=0', ''}, {'#modulename=autochangecat|test2|test3|days=0', ''}, {'#modulename=autochangecat|#fname=main|test2|test3|days=0', ''}, {'#mod=Module:If|test1|test2|test3', 'test2'}, {'#mod=dev:If|test1|test2|test3', 'test2'}, {'#mod=dev:if|test1|test2|test3', 'test2'}, {'#mod=devif', 'test prefix'}, {'#mod=Devmodule/testmodule|#fname=isleapyear', ' Error: the module called `Devmodule/testmodule` on dev.wikia does not have a function called `isleapyear`. '},               {'#mod=Devmodule/testmodule',"Dev:Devmodule/testmodule:9: attempt to perform arithmetic on a string value"}, {'#mod=x_x',' Error: a module called `X_x` does not exist on dev.wikia. '},               {'#mod=if|fname=x_x',"nil"}, {'',' Error: no `#mod` parameter given (should be the name of a module on dev.wikia). '},               {'#mod=Devmodule/testmodule|#fname=dontCallMe', ' Error: leave me alone. '},               {'#mod=Devmodule/testmodule|#fname=error2', Dev:Devmodule/testmodule:15: attempt to call field '?' (a nil value)}, },       },    }, } return p