Language grammar specification and test helpers