[Pkg-javascript-commits] [node-nan] 09/10: Fix runtestsuite

Bastien Roucariès rouca at moszumanska.debian.org
Wed Sep 6 19:43:46 UTC 2017


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

rouca pushed a commit to branch master
in repository node-nan.

commit ac9e320f31b6e72eb37097fcffbfc2ab93b0710f
Author: Bastien ROUCARIÈS <roucaries.bastien at gmail.com>
Date:   Wed Sep 6 17:44:38 2017 +0200

    Fix runtestsuite
---
 debian/control            |  2 +-
 debian/tests/runtestsuite | 15 ++++++++++++++-
 2 files changed, 15 insertions(+), 2 deletions(-)

diff --git a/debian/control b/debian/control
index 72c3f69..d54f95d 100644
--- a/debian/control
+++ b/debian/control
@@ -1,6 +1,6 @@
 Source: node-nan
 Section: javascript
-Priority: optionnal
+Priority: optional
 Maintainer: Debian Javascript Maintainers <pkg-javascript-devel at lists.alioth.debian.org>
 Uploaders:
  Jérémy Lal <kapouer at melix.org>,
diff --git a/debian/tests/runtestsuite b/debian/tests/runtestsuite
index 454cf23..b231d67 100755
--- a/debian/tests/runtestsuite
+++ b/debian/tests/runtestsuite
@@ -1,13 +1,26 @@
 #!/bin/sh
 set -e
 
+# for verbose make
+V=1
+export V
+
 tmpdir=$(mktemp -d)
 trap 'rm -rf "$tmpdir"' EXIT INT TERM HUP
 
+sed_move_to_stderr() {
+    sed  -e "/$1/w /dev/stderr" -e "/$1/d"
+}
+
 
 cp -r test "$tmpdir"
 cd "$tmpdir"
 sed -i "s/require('..')/require('nan')/g" test/binding.gyp
-V=1 node-gyp rebuild --directory test
+exec 5>&1
+exec 3>&1
+error_gyp=$( ( (node-gyp rebuild --directory test 2>&1 >&3 3>&- ; echo $? >&4)  | sed_move_to_stderr 'it worked if it ends' 2>&1 >&3 3>&- ) 4>&1 >&5)
+exec 3>&-
+exec 5>&-
+test "X$error_gyp" = "X0"
 tap -R spec --gc test/js/*-test.js
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-nan.git



More information about the Pkg-javascript-commits mailing list