You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: contributing.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@
4
4
5
5
Please note that this project is released with a [Contributor Code of Conduct](code-of-conduct.md). By participating in this project you agree to abide by its terms.
As AVA [spawns the test files][isolated-env], you can't use [`istanbul`] for code coverage; instead, you can achieve this with [`nyc`] which is basically [`istanbul`] with sub-process support.
5
+
As AVA [spawns the test files][isolated-env], you can't use [`istanbul`] for code coverage; instead, you can achieve this with [`nyc`] which is basically [`istanbul`] with sub-process support.
6
6
7
7
## Setup
8
8
@@ -35,16 +35,16 @@ Using NYC to provide coverage for production code written in ES5 is simple. Just
35
35
```
36
36
37
37
That's it!
38
-
39
-
If you want to create HTML coverage reports, or upload coverage data to Coveralls, you should skip down to those sections below.
38
+
39
+
If you want to create HTML coverage reports, or upload coverage data to Coveralls, you should skip down to those sections below.
40
40
41
41
## ES2015 coverage
42
42
43
43
Using Babel to transpile your production code is a bit more involved. Here we've broken it down into multiple steps.
44
44
45
45
### Configure Babel
46
46
47
-
First, we need a Babel configuration. The following is just an example. You will need to modify it to fit your needs.
47
+
First, we need a Babel configuration. The following is just an example. You will need to modify it to fit your needs.
48
48
49
49
`package.json`:
50
50
```json
@@ -89,7 +89,7 @@ Note that the build script really has very little to do with AVA, and is just a
89
89
90
90
### Use the Babel require hook
91
91
92
-
To use the Babel require hook, add `babel-core/register` to the `require` section of you AVA config in `package.json`.
92
+
To use the Babel require hook, add `babel-core/register` to the `require` section of you AVA config in `package.json`.
93
93
94
94
```json
95
95
{
@@ -106,7 +106,7 @@ To use the Babel require hook, add `babel-core/register` to the `require` sectio
106
106
Combining the above steps, your complete `package.json` should look something like this:
AVA doesn't have a builtin method for testing endpoints, but you can use any assertion library with it. Let's use [`supertest-as-promised`](https://github.com/WhoopInc/supertest-as-promised).
0 commit comments