[perl-BackPAN-Index] patch TestUtils.pm to use local backpan index

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



commit cca39a88e023e24d51d36cf7593972b72a837d97
Author: Iain Arnell <iarnell@xxxxxxxxx>
Date:   Sun Mar 20 10:52:49 2011 +0100

    patch TestUtils.pm to use local backpan index

 perl-BackPAN-Index.spec |    4 ++++
 test-no-internet.patch  |   21 +++++++++++++++++++++
 2 files changed, 25 insertions(+), 0 deletions(-)
---
diff --git a/perl-BackPAN-Index.spec b/perl-BackPAN-Index.spec
index bf8178e..e47cda7 100644
--- a/perl-BackPAN-Index.spec
+++ b/perl-BackPAN-Index.spec
@@ -6,6 +6,8 @@ License:        GPL+ or Artistic
 Group:          Development/Libraries
 URL:            http://search.cpan.org/dist/BackPAN-Index/
 Source0:        http://www.cpan.org/authors/id/M/MS/MSCHWERN/BackPAN-Index-%{version}.tar.gz
+# force tests to run with local backpan index
+Patch0:         test-no-internet.patch
 BuildArch:      noarch
 BuildRequires:  perl(App::Cache) >= 0.37
 BuildRequires:  perl(Archive::Extract)
@@ -48,6 +50,7 @@ for efficient querying.
 
 %prep
 %setup -q -n BackPAN-Index-%{version}
+%patch0 -p 1
 
 sed -i -e '1s~^#!.*perl~#!%{__perl}~' examples/backpan.pl
 
@@ -74,6 +77,7 @@ BACKPAN_INDEX_TEST_NO_INTERNET=1 ./Build test
 * Sun Mar 20 2011 Iain Arnell <iarnell@xxxxxxxxx> 0.40-1
 - update to latest upstream version
 - run tests with BACKPAN_INDEX_TEST_NO_INTERNET
+- patch TestUtils.pm to force BACKPAN_INDEX_TEST_NO_INTERNET
 
 * Tue Feb 08 2011 Fedora Release Engineering <rel-eng@xxxxxxxxxxxxxxxxxxxxxxx> - 0.39-3
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
diff --git a/test-no-internet.patch b/test-no-internet.patch
new file mode 100644
index 0000000..be341f0
--- /dev/null
+++ b/test-no-internet.patch
@@ -0,0 +1,21 @@
+diff -up BackPAN-Index-0.40/t/lib/TestUtils.pm.orig BackPAN-Index-0.40/t/lib/TestUtils.pm
+--- BackPAN-Index-0.40/t/lib/TestUtils.pm.orig	2011-03-01 01:59:30.000000000 +0100
++++ BackPAN-Index-0.40/t/lib/TestUtils.pm	2011-03-20 10:50:09.000000000 +0100
+@@ -39,7 +39,7 @@ sub backpan_index_url {
+ # Init a new BackPAN::Index object with the right options for testing
+ sub new_backpan {
+     my %args = @_;
+-    $args{backpan_index_url} = backpan_index_url() if $args{update};
++    $args{backpan_index_url} = backpan_index_url();
+ 
+     return BackPAN::Index->new({
+         cache_dir               => cache_dir(),
+@@ -50,7 +50,7 @@ sub new_backpan {
+ 
+ sub new_pbp {
+     my %args = @_;
+-    $args{backpan_index_url} = backpan_index_url() if $args{update};
++    $args{backpan_index_url} = backpan_index_url();
+ 
+     require Parse::BACKPAN::Packages;
+     return Parse::BACKPAN::Packages->new({
--
Fedora Extras Perl SIG
http://www.fedoraproject.org/wiki/Extras/SIGs/Perl
perl-devel mailing list
perl-devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/perl-devel


[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Legacy Announce]     [Fedora PHP Devel]     [Kernel Devel]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Big List of Linux Books]     [Gimp]     [Yosemite Information]
  Powered by Linux