Manual:Pre-commit checklist

This is an attempt to create a checklist to use before making a commit. Some of this duplicates what is in the coding conventions, but is in the form of quick checks. This checklist is in the same vein as The Checklist Manifesto. Some of these may seem silly (like asking a doctor “did you wash your hands?”) but they're meant to avoid problems that may be overlooked.


 * Did your code run without errors under ?
 * Have you tested all exit points from your code?
 * Did you use tabs instead of spaces to indent?
 * If you've created a new function, did you document the function parameters and what it returns using PHPDoc?
 * Whitespace trailing at the end of lines is annoying, don't do that (but don't fix whitespace at the end of lines you didn't modify in the same commit, just make sure whatever you touched is good, see next point:)
 * Does this commit contain any whitespace-only changes? They should be isolated to their own separate coding style-only commit.
 * Have you created any identifiers that didn't use CamelCase (ie. underscores)?
 * Is every exception tested?
 * If you have multiple return points, are they tested?
 * Does each message you've created exist in MessagesEn.php and listed in maintenance/languages/messages.inc?
 * Is each use of,  , etc. checked for errors or problems?
 * Did you use  or   flags for   to ensure Windows compatibility?
 * Have you used the proper output functions?   should almost never be used.
 * Have you used the proper termination functions?   should almost never be used.
 * Where appropriate, have you used the MediaWiki wrapper functions instead of their PHP equivalents?
 * instead of  to get boolean params


 * If you add a new test to parserTests.txt did you give it a new name?
 * Have you run ?

JavaScript /CSS

 * Tested in an actual browser ?
 * Compatible with IE 6.0+, FF 2.0+, Safari 3.0+, Opera 9.0+, Chrome ?
 * (JavaScript) Does it validate (or did you at least run it through) JSHint ?
 * (JavaScript) Are there any implied globals other than  or   ? There should not be, (not   either)
 * Is it DRY ?