Commit b5001ae0 authored by Hunter Loftis's avatar Hunter Loftis

test and implementation for unmet dependencies

parent 1ecc9dcb
......@@ -162,3 +162,4 @@ header "Build succeeded!"
summarize_build | output "$LOG_FILE"
warn_no_start "$LOG_FILE"
warn_unmet_dep "$LOG_FILE"
......@@ -128,3 +128,10 @@ warn_econnreset() {
warning "ECONNRESET issues may be related to npm versions" "https://github.com/npm/registry/issues/10#issuecomment-217141066"
fi
}
warn_unmet_dep() {
local log_file="$1"
if grep -qi 'unmet dependency' "$log_file" || grep -qi 'unmet peer dependency' "$log_file"; then
warn "Unmet dependencies don't fail npm install but may cause runtime issues" "https://github.com/npm/npm/issues/7494"
fi
}
{
"name": "unmet-dep",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"start": "node server.js"
},
"keywords": [],
"author": "",
"license": "ISC",
"dependencies": {
"grunt-steroids": "0.2.3"
}
}
#!/usr/bin/env bash
# See README.md for info on running these tests.
testWarnUnmetDep() {
compile "unmet-dep"
assertCaptured "may cause runtime issues"
assertCapturedSuccess
compile "no-version"
assertNotCaptured "may cause runtime issues"
assertCapturedSuccess
}
testWarnEconnreset() {
compile "econnreset-mock"
assertCaptured "may be related to npm versions"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment