Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Smoke test now uses portable file path

Added a sanity check to ensure smoke.sh is run from the correct folder
and use a relative path to the mona image so it works on any system.
  • Loading branch information...
commit 13488fa94bd6ed31d306b4c2c6cdf3973322ef97 1 parent 85e1ce2
@penguin359 penguin359 authored
Showing with 8 additions and 1 deletion.
  1. +1 −0  .gitignore
  2. +6 −0 smoke/smoke.sh
  3. +1 −1  smoke/smoketest.js
View
1  .gitignore
@@ -4,4 +4,5 @@ build
node_modules
npm-debug.log
out*.jpg
+out*.png
examples/*.avi
View
6 smoke/smoke.sh
@@ -1,4 +1,10 @@
#!/bin/bash
+
+if [ ! -f smoke/smoketest.js ]; then
+ echo "Please run smoke test from the top-level folder of the repository." >&2
+ exit 1
+fi
+
node-gyp build && echo '-- Compiled OK --
' && node smoke/smoketest.js && echo '-- Smoke Done, running tests --
View
2  smoke/smoketest.js
@@ -20,7 +20,7 @@ cv.readImage("/Users/peterbraden/Downloads/orl_faces/s6/10.pgm", function(e, im)
*/
-cv.readImage("/Users/peterbraden/Desktop/repos/node-opencv/examples/mona.png", function(e, mat){
+cv.readImage("examples/mona.png", function(e, mat){
var th = mat.threshold(200, 200, "Threshold to Zero Inverted");
th.save('out.png')
Please sign in to comment.
Something went wrong with that request. Please try again.