v3.4.2
Added
-
Add new
moodle.Files.LangFilesOrdering
sniff to check that lang files are sorted by key. -
Add new
moodle.Commenting.MissingDocBlock
sniff to check that all the artifacts (classes, interfaces, traits, ...) and functions are documented. -
Add new
moodle.Commenting.VariableComment
sniff to check that the@var
tag and its types are used correctly. -
Add new
moodle.Commenting.ValidTag
sniff to check that only allowed tags are used. -
Add new
moodle.Commenting.FileExpectedTags
sniff to check that files or classes have the correct PHPDoc block with both@copyright
and@license
information.The expected contents of the
@license
tag can be controlled both by thepreferredLicenseRegex
property in ruleset files or by themoodleLicenseRegex
configuration option inphpcs.xml
files 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.