Open Thiefyface opened 4 years ago
@Thiefyface Thanks for the report, I'll look into this.
@Thiefyface I wished to understand something. I need to generate test cases for bnf grammar. So this is what I am using:
gramminator-process bnf.g4
I get the Unlexer and Unparser python files.
Then I use:
gramminator-generate -l unlexerfile -p unparser file
I am not sure how to feed in the grammar that needs to be followed to generate the test cases. Can guide?
Heya, so I was testing out the Json grammer fuzzing and noticed alot of duplication in the output testcases. It may have been something I was doing wrong but I was following the instructions on the Readme.md.
Testcase Generation I was using (standard Unlexer/Unparser):
grammarinator-generate -l JSONUnlexer.py -p JSONUnparser.py -d 10 -n 1000000 -o json_fuzzer_test2
The above would finish incredibly fast at ~37 seconds for the 1 million testcases, which was awesome, but when testing the uniqueness for a smaller sample via "for i in `ls` ; do md5sum $i >> hashes.txt; done", I got the following:
Anyways, I wrote a patch for getting grammarinator-generate to produce unique testcases that can be found at the below. It's just a hack and could probably done better as to reduce the runtime cost. As it stands, the runtime is significantly increased, but it seems like the testcases are unique: