Repository navigation
v3.4.2
Added
-
Add new
moodle.Files.LangFilesOrderingsniff to check that lang files are sorted by key. -
Add new
moodle.Commenting.MissingDocBlocksniff to check that all the artifacts (classes, interfaces, traits, ...) and functions are documented. -
Add new
moodle.Commenting.VariableCommentsniff to check that the@vartag and its types are used correctly. -
Add new
moodle.Commenting.ValidTagsniff to check that only allowed tags are used. -
Add new
moodle.Commenting.FileExpectedTagssniff to check that files or classes have the correct PHPDoc block with both@copyrightand@licenseinformation.The expected contents of the
@licensetag can be controlled both by thepreferredLicenseRegexproperty in ruleset files or by themoodleLicenseRegexconfiguration option inphpcs.xmlfiles and CLI invocations. Setting them to empty string disables the Sniff completely. By default, the "https://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later" content is checked.
Note that all the moodle.Commenting sniffs above are part of the migration from moodle-local_moodlecheck to moodle-cs. You can find more information about the deprecation of the former and links to track the progress in the announcement in General developer forum.
Changed
- Various reorganisations of tests, fixtures and utils affecting a number of sniffs.