Make WordPress Core

Opened 23 months ago

Closed 23 months ago

Last modified 12 months ago

#42731 closed enhancement (fixed)

Add inline documentation to WP_UnitTestCase

Reported by: Frank Klein Owned by: johnbillion
Milestone: 5.1 Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: has-patch commit
Focuses: Cc:
PR Number:


The WP_UnitTestCase class is large, and complex, but it does not contain much inline documentation to make it easier to understand.

Let's change that.

Attachments (2)

42731-1.patch (11.5 KB) - added by Frank Klein 23 months ago.
42731-1.2.patch (11.5 KB) - added by Frank Klein 23 months ago.

Download all attachments as: .zip

Change History (9)

#1 @Frank Klein
23 months ago

  • Keywords has-patch added

The patch above contains part one, as it's easier to do this in phases.

#2 @netweb
23 months ago

  • Milestone changed from Awaiting Review to 5.0

Looking good Frank, a couple of things:

  • Can you update the patch to so that "back ported" is spelled as one word, i.e "backported" please
  • I think the //error_log( $file ); comment should remain, it gives a quick heads up when debugging

#3 @Frank Klein
23 months ago

Thanks for the feedback, updated the patch.

Concerning the commented out //error_log( $file );, I agree that this should not be removed in a patch that adds inline documentation.

However I am convinced that it should not remain in the file, it should just be removed as part of another ticket. Leaving commented out code behind is like leaving litter on the floor of a public place.

#4 @netweb
23 months ago

  • Keywords commit added

Thanks for the updated patch, and that sounds like a plan +1

#5 @johnbillion
23 months ago

  • Owner set to johnbillion
  • Status changed from new to reviewing

#6 @johnbillion
23 months ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 42379:

Build/Test tools: Add inline documentation to undocumented methods in the WP_UnitTestCase class.

Props Frank Klein

Fixes #42731

#7 @jorbin
12 months ago

  • Milestone changed from 5.0 to 5.1
Note: See TracTickets for help on using tickets.