[DRE-commits] [gem2deb] 04/08: test/bin/wnpp-check: mock wnpp-check, avoid hitting the network

Antonio Terceiro terceiro at moszumanska.debian.org
Tue Aug 12 01:46:27 UTC 2014


This is an automated email from the git hooks/post-receive script.

terceiro pushed a commit to branch master
in repository gem2deb.

commit 6e785fa38c5a88cdadff4ccc4d5bde03fe679f0c
Author: Antonio Terceiro <terceiro at debian.org>
Date:   Sun Aug 10 14:02:01 2014 -0300

    test/bin/wnpp-check: mock wnpp-check, avoid hitting the network
---
 debian/changelog    | 3 +++
 test/bin/wnpp-check | 3 +++
 test/test_helper.rb | 2 +-
 3 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index ac79bb6..f5977e1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,9 @@ gem2deb (0.8) UNRELEASED; urgency=medium
   * dh_ruby_fixdepends: inject minimum Ruby dependency provided by
     ruby-all-dev in the shared library dependencies. For that, bump dependency
     on ruby-all-dev to (>= 1:2.1.0.3~)
+  * test/test_helper.rb: add test/bin to $PATH during tests
+  * test/bin/wnpp-check: mock the actual wnpp-check during tests to avoid
+    hitting the network
 
  -- Antonio Terceiro <terceiro at debian.org>  Sat, 09 Aug 2014 22:35:16 -0300
 
diff --git a/test/bin/wnpp-check b/test/bin/wnpp-check
new file mode 100755
index 0000000..296ef78
--- /dev/null
+++ b/test/bin/wnpp-check
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+true
diff --git a/test/test_helper.rb b/test/test_helper.rb
index b853a7a..9ec462b 100644
--- a/test/test_helper.rb
+++ b/test/test_helper.rb
@@ -143,7 +143,7 @@ class Gem2DebTestCase
 
       # setup the environment
       ENV['PERL5LIB'] = perl5lib
-      ENV['PATH'] = [File.join(GEM2DEB_ROOT_SOURCE_DIR, 'bin'), ENV['PATH']].join(':')
+      ENV['PATH'] = [File.join(GEM2DEB_ROOT_SOURCE_DIR, 'bin'), File.join(GEM2DEB_ROOT_SOURCE_DIR, 'test', 'bin'), ENV['PATH']].join(':')
       ENV['RUBYLIB'] = File.join(GEM2DEB_ROOT_SOURCE_DIR, 'lib')
 
       @environment_setup = true

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/gem2deb.git



More information about the Pkg-ruby-extras-commits mailing list