From 824d809da6e25d2cefbfd33dde0b673736500a53 Mon Sep 17 00:00:00 2001 From: anomiex Date: Mon, 24 Feb 2025 15:07:26 +0000 Subject: [PATCH] tests: Rename and abstractify custom TestCase base classes (#41935) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PHPUnit 10+ requires that test class names match the filename, PSR-4 style. We've written a PHPUnit sniff to help find mismatches, but to work properly it needs any custom TestCase base classes to be abstract and have names ending in "TestCase" or "TestBase". This PR adds `abstract` where necessary and renames classes where necessary. In a few places this has already caused other existing PHPUnit rules to start fixing things. 😀 Committed via a GitHub action: https://github.com/Automattic/jetpack/actions/runs/13500864408 Upstream-Ref: Automattic/jetpack@18072cc1091accd6d948730473aea55766c962c9 --- composer.lock | 8 ++++---- vendor/composer/installed.json | 2 +- vendor/composer/installed.php | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/composer.lock b/composer.lock index 55ea49b4..8b539c57 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "92de4d6c72bc6464c3f1b5497f850591", + "content-hash": "fe2a1af8c6f039898ede305e9c21a24c", "packages": [ { "name": "automattic/jetpack-device-detection", @@ -12,7 +12,7 @@ "dist": { "type": "path", "url": "/tmp/jetpack-build/Automattic/jetpack-device-detection", - "reference": "da41451c1401be76130cea3e326bef27b8ae9ceb" + "reference": "e3566754d27e5a0421fe1d9a75687b917ce3ae31" }, "require": { "php": ">=7.2" @@ -63,11 +63,11 @@ "packages-dev": [ { "name": "automattic/jetpack-changelogger", - "version": "6.0.0-alpha.1740065649", + "version": "6.0.0-alpha.1740408687", "dist": { "type": "path", "url": "/tmp/jetpack-build/Automattic/jetpack-changelogger", - "reference": "380fcfdf96c7f57f786498e878982e3a0cef99d0" + "reference": "bdf0ecc2c94de8a732ff35013d7af903aa2a9b59" }, "require": { "composer-runtime-api": "^2.2.0", diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 7a5f8257..39bf1968 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -7,7 +7,7 @@ "dist": { "type": "path", "url": "/tmp/jetpack-build/Automattic/jetpack-device-detection", - "reference": "da41451c1401be76130cea3e326bef27b8ae9ceb" + "reference": "e3566754d27e5a0421fe1d9a75687b917ce3ae31" }, "require": { "php": ">=7.2" diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 02a461ad..9a22fb42 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -13,7 +13,7 @@ 'automattic/jetpack-device-detection' => array( 'pretty_version' => '3.0.0', 'version' => '3.0.0.0', - 'reference' => 'da41451c1401be76130cea3e326bef27b8ae9ceb', + 'reference' => 'e3566754d27e5a0421fe1d9a75687b917ce3ae31', 'type' => 'jetpack-library', 'install_path' => __DIR__ . '/../automattic/jetpack-device-detection', 'aliases' => array(),