[wp-trac] [WordPress Trac] #55918: Call wpTearDownAfterClass() before deleting all data, instead of after

WordPress Trac noreply at wordpress.org
Sat Jun 4 15:28:31 UTC 2022


#55918: Call wpTearDownAfterClass() before deleting all data, instead of after
--------------------------------------+---------------------
 Reporter:  SergeyBiryukov            |       Owner:  (none)
     Type:  defect (bug)              |      Status:  new
 Priority:  normal                    |   Milestone:  6.1
Component:  Build/Test Tools          |     Version:
 Severity:  normal                    |  Resolution:
 Keywords:  has-patch has-unit-tests  |     Focuses:
--------------------------------------+---------------------

Comment (by SergeyBiryukov):

 It also looks like most of `wpTearDownAfterClass()` methods in tests are
 not strictly necessary and can be removed, as the data is deleted anyway
 via `_delete_all_data()` in
 `WP_UnitTestCase_Base::tear_down_after_class()`. That can be further
 explored in #53011 or #53746.

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


More information about the wp-trac mailing list