Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add quickcheck tests for printer and parser #7

Open
flip111 opened this issue Sep 23, 2022 · 1 comment
Open

Add quickcheck tests for printer and parser #7

flip111 opened this issue Sep 23, 2022 · 1 comment
Labels
enhancement New feature or request

Comments

@flip111
Copy link

flip111 commented Sep 23, 2022

Would be nice to automatically generate some tests with a quickcheck implementation such as https://github.com/emil-e/rapidcheck

One could generate some AST, print it, parse the source code and check if the AST still matches

@jzimmerman
Copy link
Owner

I don't want to pull in yet another dependency, but for what it's worth, the lang unit tests already do the inverse of this for many inline examples: i.e., they test that PrettyPrint(Parse(str)) == str.

@jzimmerman jzimmerman added the enhancement New feature or request label Sep 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants