[Pkg-owncloud-commits] [php-sabredav] 04/13: Run the test suite on packaging
David Prévot
taffit at moszumanska.debian.org
Tue May 20 23:10:57 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository php-sabredav.
commit 65b5bf47c3bf8d189dc38f51a910e38cb2dfba40
Author: David Prévot <taffit at debian.org>
Date: Wed Mar 19 10:00:02 2014 -0400
Run the test suite on packaging
---
debian/control | 10 +++++-
...ssLoader-from-Symfony-instead-of-autoload.patch | 36 ++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 3 ++
4 files changed, 49 insertions(+), 1 deletion(-)
diff --git a/debian/control b/debian/control
index 8022659..24c0d2d 100644
--- a/debian/control
+++ b/debian/control
@@ -5,7 +5,15 @@ Maintainer: ownCloud for Debian maintainers <pkg-owncloud-maintainers at lists.alio
Uploaders: Thomas Mueller <thomas.mueller at tmit.eu>,
Paul van Tilburg <paulvt at debian.org>,
David Prévot <taffit at debian.org>
-Build-Depends: debhelper (>= 8.0.0), pkg-php-tools (>= 1.7~)
+Build-Depends: debhelper (>= 8.0.0),
+ php-sabre-event,
+ php-sabre-http,
+ php-sabre-vobject (>= 3.2.0),
+ php-symfony-classloader,
+ php5-curl,
+ php5-sqlite,
+ phpunit,
+ pkg-php-tools (>= 1.7~)
Standards-Version: 3.9.5
Homepage: http://sabre.io/dav/
Vcs-Git: git://anonscm.debian.org/pkg-owncloud/php-sabredav.git
diff --git a/debian/patches/0001-Use-ClassLoader-from-Symfony-instead-of-autoload.patch b/debian/patches/0001-Use-ClassLoader-from-Symfony-instead-of-autoload.patch
new file mode 100644
index 0000000..0f2a240
--- /dev/null
+++ b/debian/patches/0001-Use-ClassLoader-from-Symfony-instead-of-autoload.patch
@@ -0,0 +1,36 @@
+From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit at debian.org>
+Date: Tue, 20 May 2014 14:56:49 -0400
+Subject: Use ClassLoader from Symfony instead of autoload
+
+Work around the lack of proper autoload.php from composer by using the
+ClassLoader element from Symfony.
+
+http://symfony.com/doc/current/components/class_loader/class_loader.html
+
+Forwarded: not-needed
+---
+ tests/bootstrap.php | 11 +++++++++--
+ 1 file changed, 9 insertions(+), 2 deletions(-)
+
+diff --git a/tests/bootstrap.php b/tests/bootstrap.php
+index bd96535..e21ceb1 100644
+--- a/tests/bootstrap.php
++++ b/tests/bootstrap.php
+@@ -2,8 +2,15 @@
+
+ set_include_path(__DIR__ . '/../lib/' . PATH_SEPARATOR . __DIR__ . PATH_SEPARATOR . get_include_path());
+
+-$autoLoader = include __DIR__ . '/../vendor/autoload.php';
+-$autoLoader->add('Sabre\\', __DIR__);
++require_once 'Symfony/Component/ClassLoader/ClassLoader.php';
++use Symfony\Component\ClassLoader\ClassLoader;
++$loader = new ClassLoader();
++$loader->setUseIncludePath(true);
++$loader->register();
++// The following is currently useless since ClassLoader doesn’t handle PSR-4
++$loader->addPrefixes(array(
++ 'Sabre' => __DIR__.'/../lib',
++));
+
+ date_default_timezone_set('UTC');
+
diff --git a/debian/patches/series b/debian/patches/series
new file mode 100644
index 0000000..e4166b6
--- /dev/null
+++ b/debian/patches/series
@@ -0,0 +1 @@
+0001-Use-ClassLoader-from-Symfony-instead-of-autoload.patch
diff --git a/debian/rules b/debian/rules
index 4c7add7..36170cb 100755
--- a/debian/rules
+++ b/debian/rules
@@ -4,5 +4,8 @@
override_dh_auto_clean override_dh_auto_build:
+override_dh_auto_test:
+ cd tests && phpunit
+
get-orig-source:
uscan --verbose --force --repack --rename
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/php-sabredav.git
More information about the Pkg-owncloud-commits
mailing list