Add shortcuts to simplify running PHPUnit tests for standalone plugins #1017
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
See #946 (comment): This PR adds shortcuts to simplify running PHPUnit tests for the new standalone plugins in a way that the new plugins only have to be added to
composer.json
and are then easy to test.The way the shortcuts are defined is heavily inspired by #1002.
Usage
composer test:auto-sizes
: Tests the Auto Sizes plugin on single site.composer test-multisite:auto-sizes
: Tests the Auto Sizes plugin on multisite.composer test:plugins
: Tests all standalone plugins on single site.composer test-multisite:plugins
: Tests all standalone plugins on multisite.composer test:all
: Tests all standalone plugins plus Performance Lab on single site.composer test-multisite:all
: Tests all standalone plugins plus Performance Lab on multisite.There's also an NPM shortcut specifically for the GitHub workflow to test all standalone plugins:
npm run test-php-plugins
: Wrapscomposer test:plugins
.npm run test-php-multisite-plugins
: Wrapscomposer test-multisite:plugins
.Checklist
[Focus]
orInfrastructure
label.[Type]
label.no milestone
label.