Browse files

add test for invalid engine version

  • Loading branch information...
1 parent ef979ea commit 4986728c9f1f2a68d2f10aa2c762fcdb03e0a390 @ddollar ddollar committed Jun 21, 2012
Showing with 14 additions and 0 deletions.
  1. +5 −0 bin/test
  2. +9 −0 test/package-json-invalidversion/package.json
View
5 bin/test
@@ -35,6 +35,11 @@ testPackageJsonWithoutVersion() {
assertCapturedSuccess
}
+testPackageJsonWithInvalidVersion() {
+ compile "package-json-invalidversion"
+ assertCapturedError 1 "Requested engine npm version 1.1.5 does not"
+}
+
testNothingCached() {
cache=$(mktmpdir)
compile "package-json-version" $cache
View
9 test/package-json-invalidversion/package.json
@@ -0,0 +1,9 @@
+{
+ "name": "myapp",
+ "version": "0.0.1",
+
+ "engines": {
+ "node": "0.6.11",
+ "npm": "1.1.5"
+ }
+}

0 comments on commit 4986728

Please sign in to comment.