Add fuzz tester to catch cases where parser fails#83
Add fuzz tester to catch cases where parser fails#83dillonkearns wants to merge 4 commits intomasterfrom
Conversation
|
High-level goal: it would be awesome if we changed from
to
At it's simplest, we could just use a random string and check that it should always parse without any errors. This PR has a test that does exactly that. We should use this test to catch all current problems where the parser can have an error, and once they're all fixed, we can change the type as in (1). |
|
If we want to get a little more sophisticated here, we can change the fuzzer (or add another test) that uses some specific things that could be problematic to make sure they don't cause parser errors. For example, we could throw in lots of random characters that are used in HTML tags, since that is a current area where the parser can fail. We could also add some test cases with specific invalid HTML input and check the fallback output to make sure it's what we want, since we not only want the parser to be resilient but to have reasonable fallbacks in these specific cases. |
No description provided.