summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2021-01-12 08:36:11 +0100
committerRemi Collet <remi@remirepo.net>2021-01-12 08:36:11 +0100
commit7936bfc7211ee0cbbe3e1c13094d4484f574657e (patch)
tree2543e5d2393634704213006c8f43a0f4a587737c
parent5c44d979518ff425cb1d2f80c025933402a1a260 (diff)
update to 4.1.4
sources from git snapshot
-rw-r--r--composer.json2
-rwxr-xr-xmakesrc.sh32
-rw-r--r--php-sabre-dav4.spec25
3 files changed, 48 insertions, 11 deletions
diff --git a/composer.json b/composer.json
index fa912fa..7c9596d 100644
--- a/composer.json
+++ b/composer.json
@@ -33,7 +33,7 @@
"ext-json": "*"
},
"require-dev" : {
- "friendsofphp/php-cs-fixer": "^2.16.7",
+ "friendsofphp/php-cs-fixer": "^2.17.1",
"phpstan/phpstan": "^0.12",
"phpunit/phpunit" : "^7.5 || ^8.5 || ^9.0",
"evert/phpdoc-md" : "~0.1.0",
diff --git a/makesrc.sh b/makesrc.sh
new file mode 100755
index 0000000..f9982c6
--- /dev/null
+++ b/makesrc.sh
@@ -0,0 +1,32 @@
+#!/bin/bash
+
+NAME=$(basename $PWD)
+OWNER=$(sed -n '/^%global gh_owner/{s/.* //;p}' $NAME.spec)
+PROJECT=$(sed -n '/^%global gh_project/{s/.* //;p}' $NAME.spec)
+VERSION=$(sed -n '/^Version:/{s/.* //;p}' $NAME.spec)
+COMMIT=$(sed -n '/^%global gh_commit/{s/.* //;p}' $NAME.spec)
+SHORT=${COMMIT:0:7}
+
+if [ -f $NAME-$VERSION-$SHORT.tgz ]; then
+ echo "Already there."
+else
+ echo -e "\nCreate git snapshot\nName=$NAME, Owner=$OWNER, Project=$PROJECT, Version=$VERSION\n"
+
+ echo "Cloning..."
+ rm -rf $PROJECT-$COMMIT
+ git clone https://github.com/$OWNER/$PROJECT.git $PROJECT-$COMMIT
+
+ echo "Getting commit..."
+ pushd $PROJECT-$COMMIT
+ git checkout $COMMIT || exit 1
+ cp composer.json ../composer.json
+ popd
+
+ echo "Archiving..."
+ tar czf $NAME-$VERSION-$SHORT.tgz --exclude-vcs $PROJECT-$COMMIT
+
+ echo "Cleaning..."
+ rm -rf $PROJECT-$COMMIT
+
+ echo "Done."
+fi
diff --git a/php-sabre-dav4.spec b/php-sabre-dav4.spec
index 7ffd302..272cda8 100644
--- a/php-sabre-dav4.spec
+++ b/php-sabre-dav4.spec
@@ -1,6 +1,6 @@
# remirepo/fedora spec file for php-sabre-dav4
#
-# Copyright (c) 2013-2020 Remi Collet
+# Copyright (c) 2013-2021 Remi Collet
# License: CC-BY-SA
# http://creativecommons.org/licenses/by-sa/4.0/
#
@@ -10,7 +10,7 @@
%bcond_without tests
# Github
-%global gh_commit b903eeedfbdcd6cab7935661ec6dc2d90cdf8a1e
+%global gh_commit 4258420f15425a5f128fe5cad454e00ab4a68ae5
%global gh_short %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner sabre-io
%global gh_project dav
@@ -24,14 +24,16 @@
Name: php-%{pk_vendor}-%{pk_project}%{major}
Summary: WebDAV Framework for PHP
-Version: 4.1.3
+Version: 4.1.4
Release: 1%{?dist}
URL: https://github.com/%{gh_owner}/%{gh_project}
# sabre is BSD
# assets/openiconic is MIT
License: BSD and MIT
-Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{name}-%{version}-%{gh_short}.tar.gz
+Source0: %{name}-%{version}-%{gh_short}.tgz
+# git snapshot to retrieve tests
+Source1: makesrc.sh
# replace composer autoloader
Patch0: %{name}-autoload.patch
@@ -72,7 +74,7 @@ BuildRequires: php-curl
BuildRequires: php-pdo
BuildRequires: php-json
# From composer.json, "require-dev" : {
-# "friendsofphp/php-cs-fixer": "~2.16.7",
+# "friendsofphp/php-cs-fixer": "^2.17.1",
# "phpstan/phpstan": "^0.12",
# "phpunit/phpunit" : "^7.5 || ^8.5 || ^9.0",
# "evert/phpdoc-md" : "~0.1.0",
@@ -219,16 +221,15 @@ cp -pr lib %{buildroot}%{_datadir}/php/%{ns_vendor}
cd tests
sed -e 's:@BUILDROOT@:%{buildroot}:' -i bootstrap.php
-# TODO testDeliverInsignificantRequest fails locally, not in mock
-
: Run upstream test suite against installed library
ret=0
for cmdarg in "php %{phpunit}" "php72 %{_bindir}/phpunit8" php73 php74 php80; do
if which $cmdarg; then
set $cmdarg
- $1 ${2:-%{_bindir}/phpunit9} \
- --filter '^((?!(testDeliverInsignificantRequest)).)*$' \
- || ret=1
+ for ts in sabre-dav sabre-davacl sabre-caldav sabre-carddav; do
+ $1 ${2:-%{_bindir}/phpunit9} \
+ --testsuite $ts || ret=1
+ done
fi
done
exit $ret
@@ -251,6 +252,10 @@ exit $ret
%changelog
+* Tue Jan 12 2021 Remi Collet <remi@remirepo.net> - 4.1.4-1
+- update to 4.1.4
+- sources from git snapshot
+
* Mon Nov 9 2020 Remi Collet <remi@remirepo.net> - 4.1.3-1
- update to 4.1.3