Skip to content

Commit 4cb7560

Browse files
authored
Update reports.md: use "reporter" option instead of CLI
1 parent 05396d5 commit 4cb7560

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

docs/reports.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -212,16 +212,17 @@ Additional configuration should be added to `codecept.conf.js` to print xml repo
212212

213213
```json
214214
"mocha": {
215+
"repporter": "mocha-junit-reporter",
215216
"reporterOptions": {
216217
"mochaFile": "output/result.xml"
217218
}
218219
},
219220
```
220221

221-
Execute CodeceptJS with JUnit reporter:
222+
Execute CodeceptJS:
222223

223224
```sh
224-
codeceptjs run --reporter mocha-junit-reporter
225+
codeceptjs run
225226
```
226227

227228
Result will be located at `output/result.xml` file.
@@ -315,16 +316,17 @@ Configure it to use `output` directory to print HTML reports:
315316

316317
```json
317318
"mocha": {
319+
"reporter": "mochawesome",
318320
"reporterOptions": {
319321
"reportDir": "output"
320322
}
321323
},
322324
```
323325

324-
Execute CodeceptJS with HTML reporter:
326+
Execute CodeceptJS:
325327

326328
```sh
327-
codeceptjs run --reporter mochawesome
329+
codeceptjs run
328330
```
329331

330332
Result will be located at `output/index.html` file.
@@ -388,6 +390,7 @@ Configure mocha-multi with reports that you want:
388390

389391
```json
390392
"mocha": {
393+
"reporter": "mocha-multi",
391394
"reporterOptions": {
392395
"codeceptjs-cli-reporter": {
393396
"stdout": "-",
@@ -414,10 +417,10 @@ Configure mocha-multi with reports that you want:
414417
}
415418
```
416419

417-
Execute CodeceptJS with mocha-multi reporter:
420+
Execute CodeceptJS:
418421

419422
```sh
420-
npx codeceptjs run --reporter mocha-multi
423+
npx codeceptjs run
421424
```
422425

423426
This will give you cli with steps in console and HTML report in `output` directory.

0 commit comments

Comments
 (0)