WordPress / blueprints-library

30 stars 4 forks source link

PHP Coding standards fine-tuning #59

Open reimic opened 6 months ago

reimic commented 6 months ago

With coding standards implemented and linting on the way, it is to be considered if this library should apply all WordPress coding standards.

Some of the prompts to consider:

phpcs: File operations should use WP_Filesystem methods instead of direct PHP filesystem calls.

(This library has no direct access to WordPress. And for good reason.)

phpcs: Missing doc comment for function testUnzipFileWhenUsingAbsolutePath()

(Expects docs for every test.)

phpcs: Missing short description in doc comment

(Expects description for every doc.)

phpcs: Missing @throws tag in function comment

… and more.

adamziel commented 6 months ago

phpcs: Missing @throws tag in function comment

This one sounds useful, the rest I'd disable for now. Good call. Let's pick and choose the rules that are the most useful and fine-tune them as we go.