fix(errors): properly redirect errors to outStream
test(errors): add tests for error redirections