aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Naberezny2014-02-04 16:52:09 -0800
committerMike McQuaid2014-02-05 11:41:36 +0000
commit33f192755a48fb5dccdd302a9d43f1fd39ee5c48 (patch)
tree12eb6f4aa65f07bb3a995e0e626d33696ac55e9b
parentfc9d11b0b4c4c03ca7a497424ae7fbc6f6d85347 (diff)
downloadhomebrew-33f192755a48fb5dccdd302a9d43f1fd39ee5c48.tar.bz2
node: add test
Closes #26419. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
-rw-r--r--Library/Formula/node.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/Library/Formula/node.rb b/Library/Formula/node.rb
index d32999c08..fe979b7ce 100644
--- a/Library/Formula/node.rb
+++ b/Library/Formula/node.rb
@@ -95,4 +95,13 @@ class Node < Formula
end
end
end
+
+ test do
+ path = testpath/"test.js"
+ path.write "console.log('hello');"
+
+ output = `#{bin}/node #{path}`.strip
+ assert_equal "hello", output
+ assert_equal 0, $?.exitstatus
+ end
end