Prepares JS to handle test results and compilation failures.