Adds compatibility for running full-stack tests on darwin

This adds compatibility for running the full test stack on *nix distros by changing dependency from GNU sed to perl to avoid the GNU vs BSD differences in sed. Also adds error checking to spit out any error codes.