@@ -7,9 +7,9 @@ Utilities for testing babel plugins
77[ ![ Dependencies] [ dependencyci-badge ]] [ dependencyci ]
88[ ![ version] [ version-badge ]] [ package ]
99[ ![ downloads] [ downloads-badge ]] [ npm-stat ]
10- [ ![ MIT License] [ license-badge ]] [ LICENSE ]
10+ [ ![ MIT License] [ license-badge ]] [ license ]
1111
12- [ ![ All Contributors] ( https://img.shields.io/badge/all_contributors-4 -orange.svg?style=flat-square )] ( #contributors )
12+ [ ![ All Contributors] ( https://img.shields.io/badge/all_contributors-5 -orange.svg?style=flat-square )] ( #contributors )
1313[ ![ PRs Welcome] [ prs-badge ]] [ prs ]
1414[ ![ Donate] [ donate-badge ]] [ donate ]
1515[ ![ Code of Conduct] [ coc-badge ]] [ coc ]
@@ -30,6 +30,26 @@ This is a fairly simple abstraction to help you write tests for your babel
3030plugin. It works with ` jest ` (my personal favorite) and most of it should also
3131work with ` mocha ` and ` jasmine ` .
3232
33+ <!-- START doctoc generated TOC please keep comment here to allow auto update -->
34+ <!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
35+
36+ - [ Installation] ( #installation )
37+ - [ Usage] ( #usage )
38+ - [ import] ( #import )
39+ - [ Invoke] ( #invoke )
40+ - [ options] ( #options )
41+ - [ Test Objects] ( #test-objects )
42+ - [ Examples] ( #examples )
43+ - [ Full Example + Docs] ( #full-example--docs )
44+ - [ Simple Example] ( #simple-example )
45+ - [ Inspiration] ( #inspiration )
46+ - [ Other Solutions] ( #other-solutions )
47+ - [ Contributors] ( #contributors )
48+ - [ LICENSE] ( #license )
49+
50+ <!-- END doctoc generated TOC please keep comment here to allow auto update -->
51+
52+
3353## Installation
3454
3555This module is distributed via [ npm] [ npm ] which is bundled with [ node] [ node ] and
@@ -82,7 +102,10 @@ function identifierReversePlugin() {
82102 name: ' identifier reverse' ,
83103 visitor: {
84104 Identifier (idPath ) {
85- idPath .node .name = idPath .node .name .split (' ' ).reverse ().join (' ' )
105+ idPath .node .name = idPath .node .name
106+ .split (' ' )
107+ .reverse ()
108+ .join (' ' )
86109 },
87110 },
88111 }
@@ -428,7 +451,7 @@ pluginTester({
428451
429452I've been thinking about this for a while. The API was inspired by:
430453
431- - ESLint's [ RuleTester] [ RuleTester ]
454+ - ESLint's [ RuleTester] [ ruletester ]
432455- [ @thejameskyle ] [ @thejameskyle ] 's [ tweet] [ jamestweet ]
433456
434457## Other Solutions
@@ -440,8 +463,10 @@ I've been thinking about this for a while. The API was inspired by:
440463Thanks goes to these people ([ emoji key] [ emojis ] ):
441464
442465<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
443- | [<img src="https://avatars.githubusercontent.com/u/1500684?v=3" width="100px;"/><br /><sub>Kent C. Dodds</sub>](https://kentcdodds.com)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Documentation") [🚇](#infra-kentcdodds "Infrastructure (Hosting, Build-Tools, etc)") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Tests") | [<img src="https://avatars3.githubusercontent.com/u/952783?v=3" width="100px;"/><br /><sub>james kyle</sub>](http://thejameskyle.com/)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Documentation") [👀](#review-thejameskyle "Reviewed Pull Requests") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Tests") | [<img src="https://avatars1.githubusercontent.com/u/1894628?v=3" width="100px;"/><br /><sub>Brad Bohen</sub>](https://github.com/bbohen)<br />[🐛](https://github.com/babel-utils/babel-plugin-tester/issues?q=author%3Abbohen "Bug reports") | [<img src="https://avatars0.githubusercontent.com/u/1295580?v=3" width="100px;"/><br /><sub>Kyle Welch</sub>](http://www.krwelch.com)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Documentation") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Tests") |
444- | :---: | :---: | :---: | :---: |
466+ <!-- prettier-ignore -->
467+ | [<img src="https://avatars.githubusercontent.com/u/1500684?v=3" width="100px;"/><br /><sub><b>Kent C. Dodds</b></sub>](https://kentcdodds.com)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Documentation") [🚇](#infra-kentcdodds "Infrastructure (Hosting, Build-Tools, etc)") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=kentcdodds "Tests") | [<img src="https://avatars3.githubusercontent.com/u/952783?v=3" width="100px;"/><br /><sub><b>james kyle</b></sub>](http://thejameskyle.com/)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Documentation") [👀](#review-thejameskyle "Reviewed Pull Requests") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=thejameskyle "Tests") | [<img src="https://avatars1.githubusercontent.com/u/1894628?v=3" width="100px;"/><br /><sub><b>Brad Bohen</b></sub>](https://github.com/bbohen)<br />[🐛](https://github.com/babel-utils/babel-plugin-tester/issues?q=author%3Abbohen "Bug reports") | [<img src="https://avatars0.githubusercontent.com/u/1295580?v=3" width="100px;"/><br /><sub><b>Kyle Welch</b></sub>](http://www.krwelch.com)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Code") [📖](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Documentation") [⚠️](https://github.com/babel-utils/babel-plugin-tester/commits?author=kwelch "Tests") | [<img src="https://avatars3.githubusercontent.com/u/6680299?v=4" width="100px;"/><br /><sub><b>kontrollanten</b></sub>](https://github.com/kontrollanten)<br />[💻](https://github.com/babel-utils/babel-plugin-tester/commits?author=kontrollanten "Code") |
468+ | :---: | :---: | :---: | :---: | :---: |
469+
445470<!-- ALL-CONTRIBUTORS-LIST:END -->
446471
447472This project follows the [ all-contributors] [ all-contributors ] specification.
484509[ emojis ] : https://github.com/kentcdodds/all-contributors#emoji-key
485510[ all-contributors ] : https://github.com/kentcdodds/all-contributors
486511[ lodash.merge ] : https://lodash.com/docs/4.17.4#merge
487- [ RuleTester ] : http://eslint.org/docs/developer-guide/working-with-rules#rule-unit-tests
512+ [ ruletester ] : http://eslint.org/docs/developer-guide/working-with-rules#rule-unit-tests
488513[ @thejameskyle ] : https://github.com/thejameskyle
489514[ jamestweet ] : https://twitter.com/thejameskyle/status/864359438819262465
490515[ @babel/helper-plugin-test-runner ] : https://github.com/babel/babel/tree/master/packages/babel-helper-plugin-test-runner
0 commit comments