I made a fuzz-test thingy
See original GitHub issueBranch: https://github.com/lydell/prettier/tree/esfuzz
Using: https://github.com/estools/esfuzz/
Command: npm run fuzz
.
It generates a random program and then runs it through prettier two times. No errors are supposed to be thrown, and the two outputs from prettier are supposed to be equal.
It prints the following:
<random JS>
βββββββββββββββββββββββββββββββββββββ
<prettier JS or parse errors or diff>
βββββββββββββββββββββββββββββββββββββ
<random prettier options>
βββββββββββββββββββββββββββββββββββββ
<message>
You can easily work with the results if you find something interesting:
- The random JS is written to fuzz/random.js
- The first prettier run-through is written to fuzz/prettier1.js
- The second prettier run-through is written to fuzz/prettier2.js
Example:
Feel free to close this if it is of no use π Iβll play around with it and see if I find anything interesting.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:2
- Comments:10 (10 by maintainers)
Top Results From Across the Web
What is Fuzz Testing [Complete Guide] - Code Intelligence
Fuzz Testing is a dynamic testing method used to find functional bugs and security issues in software.
Read more >Fuzz Testing: the Complete Guide about Fuzzing
In this blog post you'll discover what is fuzz testing, also known as fuzzing, and all types of fuzz testing that exist with...
Read more >A guide to fuzz testing - Testfully
Fuzz testing is a type of automated software testing; a method of discovering bugs in software by providing random input to the softwareΒ ......
Read more >Evaluating Fuzz Testing - YouTube
Fuzz testing has enjoyed great success at discovering security critical bugs in real software. Recently, researchers have devotedΒ ...
Read more >What Is Fuzz Testing and How Does It Work? - Synopsys
Fuzz testing or fuzzing is an automated software testing method that injects ... According to fuzzing.info, the term βfuzzβ was created by Professor...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Awesome! Thanks for all your work on it π
Letβs close this issue. Feel free to open up more bugs you find with it!
This is awesome! Canβt wait to see what you find.
If you look at run_spec.js we already have the infra to make sure that the ast before and after pretty print is the same