Skip to content
  • Teddy Katz's avatar
    Chore: add a fuzzer to detect bugs in core rules (#8422) · 2c207bef
    Teddy Katz authored
    * Chore: add a fuzzer to detect bugs in core rules
    
    This commit adds a fuzzer to detect bugs in core rules. The fuzzer can detect two types of problems: crashes (where a rule throws an error given a certain syntax) and autofix errors (where an autofix results in a syntax error).
    
    The fuzzer works by running eslint on randomly-generated code with a random config. The code is generated with [eslump](https://github.com/lydell/eslump), and the config is generated with the existing autoconfig logic.
    
    The fuzzer can be run with `npm run fuzz`. Eventually, I think we should add the fuzzer to the normal `npm test` build.
    
    * Pin eslump version
    
    * Update linter logic with new APIs from ESLint 4
    
    * Upgrade eslump to 1.6.0
    2c207bef