Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDaijiro Wachi <daijiro.wachi@gmail.com>2015-02-26 16:34:36 +0300
committerForrest L Norvell <forrest@npmjs.com>2015-02-27 05:57:34 +0300
commit2f6a1df3e1e3e0a3bc4abb69e40f59a64204e7aa (patch)
tree8f14818ab4bb90808918fed0222662e6ba38843c /test
parent13b4121a30a910a2b287493b5a2a79daccd04332 (diff)
run-script: only run restart lifecyle when no script
Fixes #1999, #2716.
Diffstat (limited to 'test')
-rw-r--r--test/tap/run-script.js4
-rw-r--r--test/tap/run-script/package.json3
2 files changed, 6 insertions, 1 deletions
diff --git a/test/tap/run-script.js b/test/tap/run-script.js
index 6b5ce26aa..d7681b9ac 100644
--- a/test/tap/run-script.js
+++ b/test/tap/run-script.js
@@ -103,6 +103,10 @@ test("npm run-script nonexistent-script", function (t) {
})
})
+test("npm run-script restart when there isn't restart", function (t) {
+ common.npm(["run-script", "restart"], opts, testOutput.bind(null, t, "stop;start"))
+})
+
test("cleanup", function (t) {
cleanup()
t.end()
diff --git a/test/tap/run-script/package.json b/test/tap/run-script/package.json
index ebaffefe0..761b15ffb 100644
--- a/test/tap/run-script/package.json
+++ b/test/tap/run-script/package.json
@@ -8,6 +8,7 @@
"postwith-post":"node -e \"console.log(process.argv[1] || 'post')\"",
"prewith-both":"node -e \"console.log(process.argv[1] || 'pre')\"",
"with-both":"node -e \"console.log(process.argv[1] || 'main')\"",
- "postwith-both":"node -e \"console.log(process.argv[1] || 'post')\""
+ "postwith-both":"node -e \"console.log(process.argv[1] || 'post')\"",
+ "stop":"node -e \"console.log(process.argv[1] || 'stop')\""
}
}