From 66fe2bbde36da5a28ada1629ded03e413d727d6a Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 29 Apr 2014 17:21:58 +0200 Subject: php-phpunit-PHPUnit-MockObject: 2.0.5, sources from github --- Autoload.php.in | 24 ++++++++++ php-phpunit-PHPUnit-MockObject.spec | 95 +++++++++++++++++++++---------------- 2 files changed, 78 insertions(+), 41 deletions(-) create mode 100644 Autoload.php.in diff --git a/Autoload.php.in b/Autoload.php.in new file mode 100644 index 0000000..e79223b --- /dev/null +++ b/Autoload.php.in @@ -0,0 +1,24 @@ += 1.9.4 -BuildRequires: php-channel(%{pear_channel}) +BuildRequires: %{_bindir}/phpab +%if %{with_tests} +BuildRequires: php-pear-PHPUnit >= 4.0.0 +%endif -Requires(post): %{__pear} -Requires(postun): %{__pear} -Requires: php-pear(PEAR) >= 1.9.4 +# From composer.json Requires: php(language) >= 5.3.3 +Requires: php-phpunit-Text-Template >= 1.2 +Requires: php-phpunit-Text-Template < 2 +Requires: php-pear-PHPUnit >= 4.0.0 +Requires: php-pear-PHPUnit < 4.1 +# From phpcompatinfo report for version 2.0.5 Requires: php-pcre Requires: php-reflection Requires: php-soap Requires: php-spl -Requires: php-pear(%{pear_channel}/Text_Template) >= 1.1.1 -Requires: php-pear(%{pear_channel}/PHPUnit) >= 3.7.0 +# For compatibility with PEAR mode Provides: php-pear(%{pear_channel}/%{pear_name}) = %{version} @@ -36,53 +57,45 @@ Mock Object library for PHPUnit %prep -%setup -q -c -cd %{pear_name}-%{version} -# package.xml is V2 -mv ../package.xml %{name}.xml +%setup -q -n %{gh_project}-%{gh_commit} %build -cd %{pear_name}-%{version} -# Empty build section, most likely nothing required. +phpab \ + --output src/Framework/MockObject/Autoload.php \ + --template %{SOURCE1} \ + src %install -rm -rf %{buildroot} -cd %{pear_name}-%{version} -%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml +rm -rf %{buildroot} +mkdir -p %{buildroot}%{php_home} +cp -pr src %{buildroot}%{php_home}/PHPUnit -# Clean up unnecessary files -rm -rf %{buildroot}%{pear_metadir}/.??* -# Install XML package description -mkdir -p %{buildroot}%{pear_xmldir} -install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir} +%if %{with_tests} +%check +phpunit \ + -d date.timezone=UTC \ + --bootstrap src/Framework/MockObject/Autoload.php +%endif %clean rm -rf %{buildroot} -%post -%{__pear} install --nodeps --soft --force --register-only \ - %{pear_xmldir}/%{name}.xml >/dev/null || : - -%postun -if [ $1 -eq 0 ] ; then - %{__pear} uninstall --nodeps --ignore-errors --register-only \ - %{pear_channel}/%{pear_name} >/dev/null || : -fi - - %files %defattr(-,root,root,-) -%doc %{pear_docdir}/%{pear_name} -%{pear_xmldir}/%{name}.xml -%{pear_phpdir}/PHPUnit/Framework/MockObject +%doc CONTRIBUTING.md README.md LICENSE composer.json +%{php_home}/PHPUnit/Framework/MockObject %changelog +* Tue Apr 29 2014 Remi Collet - 2.0.5-1 +- update to 2.0.5 +- sources from gthub + * Sun Jan 13 2013 Remi Collet - 1.2.3-1 - Version 1.2.3 (stable) - API 1.2.0 (stable) -- cgit