New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set PHP 7.2 as minimum version, upgrade to PHPUnit 8.5 and GuzzleHttp 7.7 #1903
Commits on Aug 14, 2023
-
Update PHPUnit minimum version to 8.5
With PHPUnit 8.5, which supports PHP >= 7.2, we no longer need the temporary changes from issue #29882 to provide PHP 8.1 compatibility. This reverts commit f82c03b by removing the dependencies on custom forks of PHPUnit and required libraries. Fixes #32810
-
- Removing phpdocumentor/reflection-common (1.0.1) - Removing phpdocumentor/reflection-docblock (4.3.4) - Removing phpdocumentor/type-resolver (0.5.1) - Removing phpspec/prophecy (v1.10.3) - Removing phpunit/phpunit-mock-objects (5.0.10) - Removing symfony/polyfill-ctype (v1.19.0) - Removing webmozart/assert (1.9.1) - Upgrading doctrine/instantiator (1.0.5 => 1.5.0) - Upgrading myclabs/deep-copy (1.7.0 => 1.11.1) - Upgrading phar-io/manifest (1.0.1 => 2.0.3) - Upgrading phar-io/version (1.0.1 => 3.2.1) - Upgrading phpunit/php-code-coverage (dev-mantis-5.3 7642884 => 7.0.15) - Upgrading phpunit/php-file-iterator (dev-mantis-1.4 89be108 => 2.0.5) - Upgrading phpunit/php-timer (1.0.9 => 2.1.3) - Upgrading phpunit/php-token-stream (2.0.2 => 3.1.3) - Upgrading phpunit/phpunit (dev-mantis-6.5 215feef => 8.5.33) - Upgrading sebastian/comparator (2.1.3 => 3.0.5) - Upgrading sebastian/diff (2.0.1 => 3.0.4) - Upgrading sebastian/environment (3.1.0 => 4.2.4) - Upgrading sebastian/exporter (3.1.4 => 3.1.5) - Upgrading sebastian/global-state (2.0.0 => 3.0.3) - Upgrading sebastian/resource-operations (1.0.0 => 2.0.2) - Locking sebastian/type (1.1.4) - Upgrading theseer/tokenizer (1.1.3 => 1.2.1)
-
-
Fix deprecated assertInternalType()
Replace with assertThat() and isType() constraint.
-
Fix deprecated @ExpectedException annotation
Replace with $this->expectException()
-
Fix deprecated assertContains() with String haystack
Replace with assertStringContainsString()
-
Fix deprecated expectExceptionMessageRegExp()
Replace with expectExceptionMessageMatches()
-
-
-
Make RestBase an abstract class
Prevents PHPUnit from throwing a warning: No tests found in class "RestBase".
-
- Removing symfony/polyfill-php72 (v1.19.0) - Removing symfony/polyfill-php70 (v1.19.0) - Removing symfony/polyfill-intl-normalizer (v1.19.0) - Removing symfony/polyfill-intl-idn (v1.19.0) - Removing paragonie/random_compat (v9.99.100) - Installing symfony/deprecation-contracts (v2.5.2) - Installing psr/http-client (1.0.2) - Upgrading guzzlehttp/guzzle (6.5.8 => 7.6.1) Fixes #32807
-
-
Fix errors when SOAP extension is not loaded
Initialize defaultSoapClientOptions property in setUp(), to avoid a syntax error due to undefined constant WSDL_CACHE_NONE. Remove useless SoapAllTests::setUp() method. TestSuite class does not have this method so it is never actually called. Extension availability check is performed by `@requires extension` hints in the test cases' PHPDoc blocks. Fixes #32814
-
Fix error when executing PHPUnit AllTests.php
Argument #1 of PHPUnit\Framework\TestSuite::addTestSuite() must be a class name or object AllTests::suite() method called addTest() instead of addTestSuite() to include the 3 tests suites. Fixes #32815
Commits on Aug 15, 2023
-
Define the Test Suites with a phpunit.xml file
Until today, the test suites were defined in "AllTests.php" files using the PHPUnit\Framework\TestSuite class, which is meant for internal use. The official, documented method to compose a test suite is to use XML configuration. This commit introduces the phpunit.xml, which replaces the AllTests.php scripts, and updates documentation and TravisCI script. Fixes #32816
-
Make UserTest uniqueness provider more dynamic
When building test email addresses, use the user and domain from the TEST_EMAIL constant, to ensure the test cases in providerEmailUnique remain relevant in case the reference email is modified.
-
Use fake sendmail script for TravisCI builds
This avoids 'sh: 1: /usr/sbin/sendmail: not found' error message displayed after PHPUnit suite execution, as sendmail is not installed on Travis. Note: This is not a "real" error and does not actually cause the build to fail, but it could lead someone reviewing the build's log to think that something went wrong, so it should be fixed to avoid confusion. The fakesendmail.sh script was copied from PHPMailer's test suite [1]. It will generate a .eml file in /tmp/fakemail directory, each time the test suite sends an email. Fixes #32828 [1]: https://github.com/PHPMailer/PHPMailer/blob/v6.8.0/test/fakesendmail.sh