Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: enrich test commands with executable #44347

Merged
merged 10 commits into from Feb 6, 2023
18 changes: 13 additions & 5 deletions BUILDING.md
Expand Up @@ -318,36 +318,44 @@ If you are updating tests and want to run tests in a single test file
(e.g. `test/parallel/test-stream2-transform.js`):

```text
$ tools/test.py test/parallel/test-stream2-transform.js
$ <python-exec> tools/test.py test/parallel/test-stream2-transform.js
```

tony-go marked this conversation as resolved.
Show resolved Hide resolved
For example on Mac it will be:

```text
$ python3 tools/test.py child-process
tony-go marked this conversation as resolved.
Show resolved Hide resolved
```

You can execute the entire suite of tests for a given subsystem
by providing the name of a subsystem:

```text
$ tools/test.py child-process
$ <python-exec> tools/test.py child-process
```

You can also execute the tests in a test suite directory
(such as `test/message`):

```text
$ tools/test.py test/message
$ <python-exec> tools/test.py test/message
```

If you want to check the other options, please refer to the help by using
the `--help` option:

```text
$ tools/test.py --help
$ <python-exec> tools/test.py --help
```

You can usually run tests directly with node:

```text
$ ./node ./test/parallel/test-stream2-transform.js
$ ./node test/parallel/test-stream2-transform.js
tony-go marked this conversation as resolved.
Show resolved Hide resolved
```

> Info: `./node` points to your local Node.js build.

Remember to recompile with `make -j4` in between test runs if you change code in
the `lib` or `src` directories.

Expand Down