[wp-trac] [WordPress Trac] #35065: Tests for docblock quality

WordPress Trac noreply at wordpress.org
Mon Dec 14 13:13:51 UTC 2015


#35065: Tests for docblock quality
------------------------------+------------------------------
 Reporter:  johnbillion       |       Owner:
     Type:  enhancement       |      Status:  new
 Priority:  normal            |   Milestone:  Awaiting Review
Component:  Build/Test Tools  |     Version:
 Severity:  normal            |  Resolution:
 Keywords:  has-patch         |     Focuses:  docs
------------------------------+------------------------------

Comment (by jdgrimes):

 Replying to [comment:4 johnbillion]:
 > Replying to [comment:3 joehoyle]:
 > > Is this not the job of some kind of code sniffer rather than unit
 testing?
 > Potentially, yes, but we don't have an infrastructure for this
 currently. [https://github.com/WordPress-Coding-Standards/WordPress-
 Coding-Standards/ WPCS] could be used, but there's nothing in there for
 docblock quality and it would have to be run separately from the PHP rules
 in WPCS because WordPress itself (naturally) doesn't yet adhere to its
 standards.

 This is actually incorrect. WPCS includes the `WordPress-Docs` ruleset for
 checking docblock quality (thanks to @GaryJ). So you can run `phpcs
 --standard=WordPress-Docs` and just check for docblock issues. It is
 possible that the rules won't match exactly what WordPress core expects,
 but PRs are welcome :-).

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35065#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list