updated parser and test cases