Added tests for MessageParser
Bug fixes.  Closes #18 and #19