Test react components with ava, no setup required.
$ npm install --global @joegesualdo/ava-react
$ ava-react <test-file>
- You must have this
.babelrc
at the root of you project:
{
"presets": [
"react",
"es2015",
'stage-0',
],
"env": {
"AVA": {
"plugins": [
[
"babel-plugin-webpack-loaders",
{
"config": "${CONFIG}",
"verbose": true
}
]
]
}
}
}
- You must have this in your
package.json
file:
{
...
"ava": {
"require": [
"babel-register"
],
"babel": "inherit"
}
...
}
$ npm test
$ npm run build
- example-package - Add description of the example package here.
MIT © undefined