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: README.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,20 +7,20 @@ to ensure your node code is correct.
7
7
8
8
## Adding to your node project dependencies
9
9
10
-
To add unit tests your node project test dependencies, add this test helper, `mocha` and `should` as follows:
10
+
To add unit tests your node project test dependencies, add this test helper as follows:
11
11
12
-
npm install mocha should node-red-node-test-helper --save-dev
12
+
npm install node-red-node-test-helper --save-dev
13
13
14
-
This will add the those modules to your `package.json` file as a development dependency. [Mocha](https://mochajs.org/) is a unit test framework for Javascript. [Should](https://shouldjs.github.io/) is an assertion library used in our example unit tests. For more information on these frameworks, see their associated documentation. Depending on your testing needs, other dev dependencies may be added.
14
+
This will add this modules to your `package.json` file as a development dependency.
15
15
16
-
Your project.json file should contain something like the following:
16
+
[Mocha](https://mochajs.org/) is a unit test framework for Javascript. [Should](https://shouldjs.github.io/) is an assertion library used in our example unit tests which will also be added to your porject. For more information on these frameworks, see their associated documentation. Depending on your testing needs, you may need to add additional dev dependencies.
17
+
18
+
Your `project.json` file should now contain something like the following:
17
19
18
20
```json
19
21
...
20
22
"devDependencies": {
21
-
"mocha": "^3.4.2",
22
-
"node-red-node-test-helper": "^0.1.3",
23
-
"should": "^8.4.0"
23
+
"node-red-node-test-helper": "^0.1.4"
24
24
}
25
25
...
26
26
```
@@ -122,7 +122,7 @@ Producing the following output (for example):
122
122
123
123
## Additional Examples
124
124
125
-
For additional examples, see the `.js` files supplied in the `test/examples` folder and the Node-RED core node test code at `test/nodes` in [the Node-RED repository](https://github.com/node-red/node-red/tree/master/test/nodes).
125
+
For additional test examples, see the `.js` files supplied in the `test/examples` folder and the Node-RED core node test code at `test/nodes` in [the Node-RED repository](https://github.com/node-red/node-red/tree/master/test/nodes).
0 commit comments