diff options
| -rw-r--r-- | php-phpdocumentor-type-resolver.spec | 40 | 
1 files changed, 17 insertions, 23 deletions
diff --git a/php-phpdocumentor-type-resolver.spec b/php-phpdocumentor-type-resolver.spec index 9f66a77..08a3d31 100644 --- a/php-phpdocumentor-type-resolver.spec +++ b/php-phpdocumentor-type-resolver.spec @@ -2,7 +2,7 @@  #  # Fedora spec file for php-phpdocumentor-type-resolver  # -# Copyright (c) 2017 Shawn Iwinski <shawn@iwin.ski> +# Copyright (c) 2017-2021 Shawn Iwinski <shawn@iwin.ski>  #  # License: MIT  # http://opensource.org/licenses/MIT @@ -20,9 +20,6 @@  # "php": "^5.5 || ^7.0"  %global php_min_ver 5.5 -# "mockery/mockery": "^0.9.4" -%global mockery_min_ver 0.9.4 -%global mockery_max_ver 1.0  # "phpdocumentor/reflection-common": "^1.0"  %global reflection_common_min_ver 1.0  %global reflection_common_max_ver 2.0 @@ -34,10 +31,9 @@  Name:          php-%{composer_vendor}-%{composer_project}  Version:       %{github_version} -Release:       5%{?github_release}%{?dist} +Release:       11%{?github_release}%{?dist}  Summary:       A PSR-5 based resolver of Class names, Types and Structural Element Names -Group:         Development/Libraries  License:       MIT  URL:           https://github.com/%{github_owner}/%{github_name} @@ -55,13 +51,10 @@ BuildRequires: php-composer(phpunit/phpunit)  # remirepo:1  %if 0%{?fedora} >= 27 || 0%{?rhel} >= 8  BuildRequires: (php-composer(phpdocumentor/reflection-common) >= %{reflection_common_min_ver} with php-composer(phpdocumentor/reflection-common) <  %{reflection_common_max_ver}) -BuildRequires: (php-composer(mockery/mockery) >= %{mockery_min_ver} with php-composer(mockery/mockery) <  %{mockery_max_ver}) -# remirepo:6 +# remirepo:4  %else  BuildRequires: php-composer(phpdocumentor/reflection-common) <  %{reflection_common_max_ver}  BuildRequires: php-composer(phpdocumentor/reflection-common) >= %{reflection_common_min_ver} -BuildRequires: php-composer(mockery/mockery) <  %{mockery_max_ver} -BuildRequires: php-composer(mockery/mockery) >= %{mockery_min_ver}  %endif  ## phpcompatinfo (computed from version 0.4.0)  BuildRequires: php-reflection @@ -136,27 +129,24 @@ cp -rp src/* %{buildroot}%{phpdir}/phpDocumentor/Reflection/  %check  %if %{with_tests}  : Create tests bootstrap -cat <<'BOOTSTRAP' | tee bootstrap.php +mkdir vendor +cat <<'BOOTSTRAP' | tee vendor/autoload.php  <?php -require '%{buildroot}%{phpdir}/phpDocumentor/Reflection/autoload-type-resolver.php'; -  \Fedora\Autoloader\Autoload::addPsr4('phpDocumentor\\Reflection\\', __DIR__.'/tests/unit'); - -\Fedora\Autoloader\Dependencies::required([ -    '%{phpdir}/Mockery/autoload.php', -]);  BOOTSTRAP -: Adjust listener path -sed 's#vendor/mockery/mockery/library#%{phpdir}#' phpunit.xml.dist > phpunit.xml +: Drop listener +(head -n 24 <phpunit.xml.dist ; tail -n1 <phpunit.xml.dist) > phpunit.xml -: Upstream tests +: Upstream tests - ignoring mockery tests  RETURN_CODE=0  PHPUNIT=$(which phpunit) -for PHP_EXEC in php php56 php70 php71 php72 php73; do +for PHP_EXEC in php php73 php74 php80; do      if [ "php" == "$PHP_EXEC" ] || which $PHP_EXEC; then -        $PHP_EXEC -d auto_prepend_file=$PWD/bootstrap.php \ -            $PHPUNIT --verbose --bootstrap bootstrap.php \ +        $PHP_EXEC -d auto_prepend_file=%{buildroot}%{phpdir}/phpDocumentor/Reflection/autoload-type-resolver.php \ +            $PHPUNIT \ +                 --filter '^((?!(testAddingAKeyword|testReadsAliasesFromClassReflection|testReadsAliasesFromProvidedNamespaceAndContent)).)*$' \ +                 --verbose \              || RETURN_CODE=1      fi  done @@ -167,6 +157,7 @@ exit $RETURN_CODE  %files +# remirepo:1  %{!?_licensedir:%global license %%doc}  %license LICENSE  %doc *.md @@ -180,6 +171,9 @@ exit $RETURN_CODE  %changelog +* Tue Mar 23 2021 Remi Collet <remi@remirepo.net> - 0.4.0-11 +- drop mockery/mockery usage +  * Fri Dec  7 2018 Remi Collet <remi@remirepo.net> - 0.4.0-5  - use range dependencies  | 
