wp-cli / wp-cli-tests

WP-CLI testing framework
MIT License
38 stars 23 forks source link

Fix PHP 8.2 deprecation warnings #165

Closed mrsdizzie closed 1 year ago

mrsdizzie commented 1 year ago

This fixes the following warnings I saw:

8192: Creation of dynamic property WP_CLI\Tests\Context\FeatureContext::$result is deprecated in /wp-cli-tests/src/Context/WhenStepDefinitions.php line 39

8192: Creation of dynamic property WP_CLI\Tests\Context\FeatureContext::$email_sends is deprecated in /wp-cli-dev/wp-cli-tests/src/Context/WhenStepDefinitions.php line 40

Which cause some behat tests to fail under PHP 8.2

All of the other variables in this class a very well commented, so this needs some input from anybody who has a good description of these two.

danielbachhuber commented 1 year ago

All of the other variables in this class a very well commented, so this needs some input from anybody who has a good description of these two.

@mrsdizzie Or you can install Copilot 😁

image

Thanks for the PR!