[wp-trac] [WordPress Trac] #52830: Tests: Uploads remain after running test suite.
WordPress Trac
noreply at wordpress.org
Wed Mar 17 05:17:30 UTC 2021
#52830: Tests: Uploads remain after running test suite.
------------------------------+-----------------------------
Reporter: peterwilsoncc | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Build/Test Tools | Version:
Severity: normal | Keywords:
Focuses: |
------------------------------+-----------------------------
Running the test suite (`phpunit` on the command line) in full leaves
several files remaining in the uploads directory once the tests complete:
{{{
/uploads/2021/03/waffles.jpg
/uploads/2021/03/waffles-300x200.jpg
/uploads/2021/03/waffles-150x150.jpg
}}}
Running only the media tests( `phpunit --filter Tests_Media` on the cli)
leaves a different set of files remaining after they have completed:
{{{
/uploads/2021/03/test-image-large-scaled-150x150.jpg
/uploads/2021/03/test-image-large-scaled-300x225.jpg
/uploads/2021/03/test-image-large-scaled-768x576.jpg
/uploads/2021/03/test-image-large-scaled-1024x768.jpg
}}}
I did try to tidy them up by deleting attachments manually in
`_delete_all_data()` (similar to how posts are deleted between classes in
`_delete_all_posts()`) but without success.
Related #38264
--
Ticket URL: <https://core.trac.wordpress.org/ticket/52830>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list