summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--composer.json25
-rw-r--r--php-yoast-phpunit-polyfills.spec28
2 files changed, 29 insertions, 24 deletions
diff --git a/composer.json b/composer.json
index 1631d83..ba28086 100644
--- a/composer.json
+++ b/composer.json
@@ -26,8 +26,8 @@
"security": "https://github.com/Yoast/PHPUnit-Polyfills/security/policy"
},
"require": {
- "php": ">=5.6",
- "phpunit/phpunit": "^5.7.21 || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0"
+ "php": ">=7.0",
+ "phpunit/phpunit": "^6.4.4 || ^7.0 || ^8.0 || ^9.0 || ^11.0"
},
"require-dev": {
"php-parallel-lint/php-console-highlighter": "^1.0.0",
@@ -49,31 +49,29 @@
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true
- }
+ },
+ "lock": false
},
"extra": {
"branch-alias": {
- "dev-main": "2.x-dev"
+ "dev-main": "3.x-dev"
}
},
"scripts": {
"lint7": [
- "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude src/Exceptions/Error.php --exclude src/Exceptions/TypeError.php --exclude tests/Polyfills/Fixtures/ValueObjectUnion.php --exclude tests/Polyfills/Fixtures/ValueObjectUnionNoReturnType.php"
+ "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude tests/Polyfills/Fixtures/ValueObjectUnion.php --exclude tests/Polyfills/Fixtures/ValueObjectUnionReturnType.php"
],
"lint70": [
- "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude src/Exceptions/Error.php --exclude src/Exceptions/TypeError.php --exclude tests/Polyfills/Fixtures/ValueObject.php --exclude tests/Polyfills/Fixtures/ValueObjectUnion.php --exclude tests/Polyfills/Fixtures/ValueObjectUnionNoReturnType.php"
- ],
- "lint-lt70": [
- "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude src/TestCases/TestCasePHPUnitGte8.php --exclude src/TestListeners/TestListenerDefaultImplementationPHPUnitGte7.php --exclude tests/Polyfills/Fixtures/ChildValueObject.php --exclude tests/Polyfills/Fixtures/ValueObject.php --exclude tests/Polyfills/Fixtures/ValueObjectUnion.php --exclude tests/Polyfills/Fixtures/ValueObjectUnionNoReturnType.php"
+ "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude src/Exceptions/Error.php --exclude src/Exceptions/TypeError.php --exclude tests/Polyfills/Fixtures/ValueObjectParamNotRequired.php --exclude tests/Polyfills/Fixtures/ValueObjectNullableReturnType.php --exclude tests/Polyfills/Fixtures/ValueObjectUnion.php --exclude tests/Polyfills/Fixtures/ValueObjectUnionReturnType.php"
],
"lint-gte80": [
"@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git"
],
"lint-gte84": [
- "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git --exclude tests/Polyfills/Fixtures/ValueObjectNoReturnType.php"
+ "@php ./vendor/php-parallel-lint/php-parallel-lint/parallel-lint . -e php --show-deprecated --exclude vendor --exclude .git"
],
"check-cs": [
- "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --runtime-set testVersion 5.6-"
+ "@php ./vendor/squizlabs/php_codesniffer/bin/phpcs --runtime-set testVersion 7.0-"
],
"fix-cs": [
"@php ./vendor/squizlabs/php_codesniffer/bin/phpcbf"
@@ -94,14 +92,13 @@
"scripts-descriptions": {
"lint7": "Check the PHP files for parse errors. (PHP 7.1 - 7.4)",
"lint70": "Check the PHP files for parse errors. (PHP 7.0)",
- "lint-lt70": "Check the PHP files for parse errors. (PHP < 7.0)",
"lint-gte80": "Check the PHP files for parse errors. (PHP 8.0 - 8.3)",
"lint-gte84": "Check the PHP files for parse errors. (PHP 8.4+)",
"check-cs": "Check the PHP files for code style violations and best practices.",
"fix-cs": "Auto-fix code style violations in the PHP files.",
"test": "Run the unit tests without code coverage (PHPUnit < 10).",
"coverage": "Run the unit tests with code coverage (PHPUnit < 10).",
- "test10": "Run the unit tests without code coverage using the PHPUnit 10 configuration file.",
- "coverage10": "Run the unit tests with code coverage using the PHPUnit 10 configuration file."
+ "test10": "Run the unit tests without code coverage using the PHPUnit 10/11 configuration file.",
+ "coverage10": "Run the unit tests with code coverage using the PHPUnit 10/11 configuration file."
}
}
diff --git a/php-yoast-phpunit-polyfills.spec b/php-yoast-phpunit-polyfills.spec
index 5b65bf8..1a3dd81 100644
--- a/php-yoast-phpunit-polyfills.spec
+++ b/php-yoast-phpunit-polyfills.spec
@@ -7,7 +7,7 @@
# Please preserve changelog entries
#
# Github
-%global gh_commit 4a088f125c970d6d6ea52c927f96fe39b330d0f1
+%global gh_commit 19e6d5fb8aad31f731f774f9646a10c64a8843d2
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner Yoast
%global gh_project PHPUnit-Polyfills
@@ -18,12 +18,12 @@
%global ns_vendor Yoast
%global ns_project PHPUnitPolyfills
# don't change major version used in package name
-%global major 2
+%global major 3
%bcond_without tests
%global php_home %{_datadir}/php
Name: php-%{pk_vendor}-%{pk_project}
-Version: 2.0.1
+Version: 3.0.0
Release: 1%{?dist}
Summary: Set of polyfills for changed PHPUnit functionality
@@ -35,20 +35,22 @@ Source1: makesrc.sh
BuildArch: noarch
%if %{with tests}
-BuildRequires: php(language) >= 5.6
+BuildRequires: php(language) >= 7.0
BuildRequires: php-reflection
# From composer.json, "require-dev": {
# "yoast/yoastcs": "^2.3.0"
-BuildRequires: phpunit10
+# remirepo:1
+BuildRequires: phpunit11
+# phpunit10 is not supported
BuildRequires: phpunit9
BuildRequires: phpunit8
%endif
BuildRequires: php-fedora-autoloader-devel
# From composer.json, "require": {
-# "php": ">=5.6",
-# "phpunit/phpunit": "^5.7.21 || ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0"
-Requires: php(language) >= 5.6
+# "php": ">=7.0",
+# "phpunit/phpunit": "^6.4.4 || ^7.0 || ^8.0 || ^9.0 || ^11.0"
+Requires: php(language) >= 7.0
# from phpcompatinfo report on version 0.2.0
Requires: php-reflection
@@ -106,10 +108,10 @@ if [ -x %{_bindir}/phpunit9 ]; then
fi
done
fi
-if [ -x %{_bindir}/phpunit10 ]; then
+if [ -x %{_bindir}/phpunit11 ]; then
for cmd in php php82 php83 php84; do
if which $cmd; then
- $cmd %{_bindir}/phpunit10 --no-coverage || ret=1
+ $cmd %{_bindir}/phpunit11 --no-coverage || ret=1
fi
done
fi
@@ -126,6 +128,12 @@ exit $ret
%changelog
+* Mon Sep 9 2024 Remi Collet <remi@remirepo.net> - 3.0.0-1
+- update to 3.0.0
+- move to /usr/share/php/Yoast/PHPUnitPolyfills3
+- raise dependency on PHP 7.0
+- drop phpunit10, add phpunit11
+
* Fri Aug 30 2024 Remi Collet <remi@remirepo.net> - 2.0.1-1
- update to 2.0.1
- move to /usr/share/php/Yoast/PHPUnitPolyfills2