Fixed some of the issues found in review and formatted test source.