2016-01-05 18:09:12 +00:00
|
|
|
# mocha
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
> Execute Mocha JavaScript test runner.
|
2019-06-04 10:25:13 +01:00
|
|
|
> More information: <https://mochajs.org>.
|
2016-01-05 18:09:12 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Run tests with default configuration or as configured in `mocha.opts`:
|
2016-01-05 18:09:12 +00:00
|
|
|
|
|
|
|
`mocha`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Run tests contained at a specific location:
|
2016-01-05 18:09:12 +00:00
|
|
|
|
2019-02-11 18:00:49 +00:00
|
|
|
`mocha {{directory/with/tests}}`
|
2016-01-05 18:09:12 +00:00
|
|
|
|
pages*: fix brand and technical names (#12145)
* pages*: fix Python, Java, pacman, apt, *zip*, xz, tar, git, RPM and grep names
* pages*: fix brand and technical names
Co-authored-by: Lena <126529524+acuteenvy@users.noreply.github.com>
* fluxctl, gitmoji, in-toto-run, osv-scanner: replace `git` with Git
* bzegrep: enclose egrep with backticks
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* git-bug: use Git instead of `git`
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* git-bug: use Git instead of `git`
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* git-force-clone: use Git instead of `git`
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* gitwatch: use Git instead of `git`
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* hub-init: use Git instead of `git`
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
* pages.*: use Linux instead of GNU/Linux
---------
Co-authored-by: Lena <126529524+acuteenvy@users.noreply.github.com>
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
2024-01-30 04:46:32 +00:00
|
|
|
- Run tests that match a specific `grep` pattern:
|
2016-01-05 18:09:12 +00:00
|
|
|
|
2021-05-10 10:03:12 +01:00
|
|
|
`mocha --grep {{regular_expression}}`
|
2016-01-05 18:09:12 +00:00
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Run tests on changes to JavaScript files in the current directory and once initially:
|
2016-01-05 18:09:12 +00:00
|
|
|
|
|
|
|
`mocha --watch`
|
|
|
|
|
2016-01-07 17:31:27 +00:00
|
|
|
- Run tests with a specific reporter:
|
2016-01-05 18:09:12 +00:00
|
|
|
|
|
|
|
`mocha --reporter {{reporter}}`
|