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

Testing against source files? #5

Closed
sogaiu opened this issue Sep 12, 2020 · 1 comment
Closed

Testing against source files? #5

sogaiu opened this issue Sep 12, 2020 · 1 comment
Labels
question Further information is requested

Comments

@sogaiu
Copy link

sogaiu commented Sep 12, 2020

I've also worked on a grammar for Fennel and have collected a list of repositories which I test against: repositories-list.txt

With clones of those made locally (e.g. under ~/src/fennel-repositories) from a tree-sitter grammar repository I typically do something like:

$ find ~/src/fennel-repositories -type f -regex '.*\.fnl' -print0 | xargs -0 npx tree-sitter parse --quiet > 2020-09-12.txt

Then I examine the results, investigate issues, tweak the grammar, etc.

May be you do something like this already, but FWIW.

@TravonteD
Copy link
Owner

Interesting idea! Currently I use the testing suite that comes with tree-sitter, and for examining errors I use playground to examine the syntax tree for different files. I appreciate the list and I will go through it to see if I can find things to improve.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants