As a general rule of thumb, I like to test exit paths (error or otherwise) to ensure the module is killing the process when expected. If we are returning from an erroneous exec or spawnSync call , ensure we are forwarding the exit code properly. (See dotnet-build.test.js for an example of this)
Add coverage where you see the most value - Jest will usually mark description() functions as having missed coverage, but seeing as we only use these for printing out text to the UI help menu, there's little value in testing that.
Backfill tests for
node-restore
moduleAs a general rule of thumb, I like to test exit paths (error or otherwise) to ensure the module is killing the process when expected. If we are returning from an erroneous
exec
orspawnSync
call , ensure we are forwarding the exit code properly. (Seedotnet-build.test.js
for an example of this)Add coverage where you see the most value - Jest will usually mark
description()
functions as having missed coverage, but seeing as we only use these for printing out text to the UI help menu, there's little value in testing that.