mirror of
git://develop.git.wordpress.org/
synced 2025-03-15 09:29:48 +01:00
Build/Test Tools: Enable testing for PHP 8.4.
With PHP 8.4 due out in November later this year, contributors have been working on ensuring WordPress 6.7 is as compatible as possible. Enough progress has been made during this release cycle where PHPUnit tests now run successfully with no failures reported. This change enables PHP 8.4 testing throughout Core’s GitHub Action workflows to ensure no new problems are introduced going forward. There are two exceptions to this: - The Importer plugin has some compatibility issues that produce test failures. There is an open pull request upstream, but these problematic tests have been marked skipped when running on PHP 8.4 until that PR is merged. - Since no stable versions of xDebug with PHP 8.4 support have been published, these tests are also skipped for now. Props jrf, desrosj. See #62061. git-svn-id: https://develop.svn.wordpress.org/trunk@59168 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
c5108d1958
commit
2c17f65542
4
.github/workflows/phpunit-tests.yml
vendored
4
.github/workflows/phpunit-tests.yml
vendored
@ -45,7 +45,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ ubuntu-latest ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ]
|
||||
db-type: [ 'mysql' ]
|
||||
db-version: [ '5.7', '8.0', '8.1', '8.2', '8.3' ]
|
||||
tests-domain: [ 'example.org' ]
|
||||
@ -116,7 +116,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ ubuntu-latest ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ]
|
||||
db-type: [ 'mariadb' ]
|
||||
db-version: [ '10.4', '10.6', '10.11', '11.2' ]
|
||||
multisite: [ false, true ]
|
||||
|
@ -182,7 +182,7 @@ jobs:
|
||||
|
||||
# __fakegroup__ is excluded to force PHPUnit to ignore the <exclude> settings in phpunit.xml.dist.
|
||||
- name: Run (Xdebug) tests
|
||||
if: ${{ inputs.php != '8.3' }}
|
||||
if: ${{ inputs.php != '8.4' }}
|
||||
continue-on-error: ${{ inputs.allow-errors }}
|
||||
run: LOCAL_PHP_XDEBUG=true node ./tools/local-env/scripts/docker.js run php ./vendor/bin/phpunit -v --group xdebug --exclude-group __fakegroup__
|
||||
|
||||
|
6
.github/workflows/upgrade-testing.yml
vendored
6
.github/workflows/upgrade-testing.yml
vendored
@ -43,7 +43,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ 'ubuntu-latest' ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3' ]
|
||||
php: [ '7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3', '8.4' ]
|
||||
db-type: [ 'mysql' ]
|
||||
db-version: [ '5.7', '8.0' ]
|
||||
wp: [ '6.0', '6.1', '6.2', '6.3', '6.4', '6.5', '6.6' ]
|
||||
@ -93,7 +93,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ 'ubuntu-latest' ]
|
||||
php: [ '8.0', '8.1', '8.2', '8.3' ]
|
||||
php: [ '8.0', '8.1', '8.2', '8.3', '8.4' ]
|
||||
db-type: [ 'mysql' ]
|
||||
db-version: [ '5.7', '8.0' ]
|
||||
wp: [ '5.3', '5.4', '5.5', '5.6', '5.7', '5.8', '5.9' ]
|
||||
@ -143,7 +143,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ 'ubuntu-latest' ]
|
||||
php: [ '8.0', '8.1', '8.2', '8.3' ]
|
||||
php: [ '8.0', '8.1', '8.2', '8.3', '8.4' ]
|
||||
db-type: [ 'mysql' ]
|
||||
db-version: [ '5.7', '8.0' ]
|
||||
wp: [ '4.1', '4.2', '4.3', '4.4', '4.5' ]
|
||||
|
@ -6,7 +6,8 @@
|
||||
"8.0",
|
||||
"8.1",
|
||||
"8.2",
|
||||
"8.3"
|
||||
"8.3",
|
||||
"8.4"
|
||||
],
|
||||
"6-6": [
|
||||
"7.2",
|
||||
|
@ -25,6 +25,10 @@ class Tests_Import_Parser extends WP_Import_UnitTestCase {
|
||||
* @covers WXR_Parser_XML::parse
|
||||
*/
|
||||
public function test_malformed_wxr() {
|
||||
if ( PHP_VERSION_ID >= 80400 ) {
|
||||
$this->markTestSkipped( 'The Importer plugin is not ready for PHP 8.4 yet. This skip should be removed once it is.' );
|
||||
}
|
||||
|
||||
$file = DIR_TESTDATA . '/export/malformed.xml';
|
||||
|
||||
// Regex based parser cannot detect malformed XML.
|
||||
@ -42,6 +46,10 @@ class Tests_Import_Parser extends WP_Import_UnitTestCase {
|
||||
* @covers WXR_Parser_Regex::parse
|
||||
*/
|
||||
public function test_invalid_wxr() {
|
||||
if ( PHP_VERSION_ID >= 80400 ) {
|
||||
$this->markTestSkipped( 'The Importer plugin is not ready for PHP 8.4 yet. This skip should be removed once it is.' );
|
||||
}
|
||||
|
||||
$f1 = DIR_TESTDATA . '/export/missing-version-tag.xml';
|
||||
$f2 = DIR_TESTDATA . '/export/invalid-version-tag.xml';
|
||||
|
||||
@ -61,6 +69,10 @@ class Tests_Import_Parser extends WP_Import_UnitTestCase {
|
||||
* @covers WXR_Parser_Regex::parse
|
||||
*/
|
||||
public function test_wxr_version_1_1() {
|
||||
if ( PHP_VERSION_ID >= 80400 ) {
|
||||
$this->markTestSkipped( 'The Importer plugin is not ready for PHP 8.4 yet. This skip should be removed once it is.' );
|
||||
}
|
||||
|
||||
$file = DIR_TESTDATA . '/export/valid-wxr-1.1.xml';
|
||||
|
||||
foreach ( array( 'WXR_Parser_SimpleXML', 'WXR_Parser_XML', 'WXR_Parser_Regex' ) as $p ) {
|
||||
@ -159,6 +171,10 @@ class Tests_Import_Parser extends WP_Import_UnitTestCase {
|
||||
* @covers WXR_Parser_Regex::parse
|
||||
*/
|
||||
public function test_wxr_version_1_0() {
|
||||
if ( PHP_VERSION_ID >= 80400 ) {
|
||||
$this->markTestSkipped( 'The Importer plugin is not ready for PHP 8.4 yet. This skip should be removed once it is.' );
|
||||
}
|
||||
|
||||
$file = DIR_TESTDATA . '/export/valid-wxr-1.0.xml';
|
||||
|
||||
foreach ( array( 'WXR_Parser_SimpleXML', 'WXR_Parser_XML', 'WXR_Parser_Regex' ) as $p ) {
|
||||
@ -257,6 +273,10 @@ class Tests_Import_Parser extends WP_Import_UnitTestCase {
|
||||
* @covers WXR_Parser_Regex::parse
|
||||
*/
|
||||
public function test_escaped_cdata_closing_sequence() {
|
||||
if ( PHP_VERSION_ID >= 80400 ) {
|
||||
$this->markTestSkipped( 'The Importer plugin is not ready for PHP 8.4 yet. This skip should be removed once it is.' );
|
||||
}
|
||||
|
||||
$file = DIR_TESTDATA . '/export/crazy-cdata-escaped.xml';
|
||||
|
||||
foreach ( array( 'WXR_Parser_SimpleXML', 'WXR_Parser_XML', 'WXR_Parser_Regex' ) as $p ) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user