#54112 closed task (blessed) (fixed)
Remove the phpunit container from the local environment
Reported by: | johnbillion | Owned by: | hellofromTonya |
---|---|---|---|
Milestone: | 5.9 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Build/Test Tools | Keywords: | has-patch commit |
Focuses: | Cc: |
Description
Slack discussion: https://wordpress.slack.com/archives/C03B0H5J0/p1631037586216900
The reason for the original introduction of the PHP+PHPUnit container at wordpressdevelop/phpunit
is so that a specific version of PHPUnit can be run on a specific version of PHP, and so that old versions of both PHP and PHPUnit that aren't supported by Composer can be used (eg. PHPUnit 3 on PHP 5.2). See #47767 for its introduction.
Since then:
- In #46594 and the linked commits, the minimum supported PHP version was increased to 5.6.
- In #46815 the management of the PHPUnit dependency was moved to Composer.
- In #46149 the running of the PHPUnit tests was mostly moved to using PHPUnit provided by Composer in the
vendor
directory.
This means we no longer need to worry about running versions of PHP or PHPUnit that aren't supported by or available on Composer. If a user wishes to switch between PHP versions locally they can do so in .env
, reload their local environment, and the yoast/phpunit-polyfills
Composer dependency will take care of using the correct version of PHPUnit.
As far as I can see this means there is no longer a need for core to keep the wordpressdevelop/phpunit
container as a service in docker-compose.yml
. Removing it will reduce the overhead and bandwidth needed to set up WordPress locally and will remove confusion about its use.
Change History (5)
This ticket was mentioned in PR #1669 on WordPress/wordpress-develop by johnbillion.
3 years ago
#1
- Keywords has-patch added
#2
@
3 years ago
- Milestone changed from Awaiting Review to 5.9
- Owner set to hellofromTonya
- Status changed from new to reviewing
hellofromtonya commented on PR #1669:
3 years ago
#5
Committed via changeset https://core.trac.wordpress.org/changeset/51868.
Trac ticket: https://core.trac.wordpress.org/ticket/54112