please-upgrade-node icon indicating copy to clipboard operation
please-upgrade-node copied to clipboard

Throw error instead of using process.exit()

Open BryanTorreblanca00 opened this issue 3 years ago • 0 comments

👋 Hello first time contributor here,

This PR attempts to resolve #20 by throwing an error when a user needs to upgrade a node version. This will allow callers to gracefully handle the error and as mentioned in the issue, won't disrupt any asynchronous execution.

One thing to mention in this PR is we no longer check the error message in the tests, I'm unsure how to assert the error of t.throws().

Feedback appreciated! Thanks.

BryanTorreblanca00 avatar Oct 03 '22 02:10 BryanTorreblanca00