Regression tests for parser

See #829.