Added parsing functionality and test