docs: add tips for building first before running test for contribute Nextjs. (#41379)

close https://github.com/vercel/next.js/issues/41378

add tips for building first before running tests for contribute Nextjs

## Documentation / Examples

- [x] Make sure the linting passes by running `pnpm lint`
This commit is contained in:
teobler 2022-10-13 11:45:08 +08:00 committed by GitHub
parent 7fc301d0b5
commit 830750af30
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2,6 +2,14 @@
## Running tests
Before you start to run tests, you need to build project first:
```bash
pnpm build
```
And for more detail about building, you can check out [building.md](./building.md)
We recommend running the tests in headless mode (with the browser windows hidden) and with a specific directory pattern and/or test name (`-t`) which ensures only a small part of the test suite is run locally:
For example, running one test in the production test suite: