Skip to content

Commit d9dd965

Browse files
author
Brian Vaughn
authored
Added testing instructions to devtools contributing guide
1 parent 9f88b53 commit d9dd965

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

packages/react-devtools/CONTRIBUTING.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
Intrested in contributing to React DevTools, but not sure where to start? This is the place!
23

34
# Install project dependencies
@@ -63,6 +64,16 @@ This will launch a standalone version of Chrome with the locally built React Dev
6364
yarn build:chrome && yarn test:chrome --url=<url-to-test>
6465
```
6566

67+
# Unit tests
68+
Core DevTools functionality is typically unit tested (see [here](https://github.com/facebook/react/tree/main/packages/react-devtools-shared/src/__tests__) and [here](https://github.com/facebook/react/tree/main/packages/react-devtools-extensions/src/__tests__)). To run tests, you'll first need to build or download React and React DOM ([as explained above](#build-react-and-react-dom)) and then use the following NPM script:
69+
```sh
70+
yarn test-build-devtools
71+
```
72+
You can connect tests to a debugger as well if you'd like by running:
73+
```sh
74+
yarn debug-test-build-devtools
75+
```
76+
6677
# Finding the right first issue
6778
The React team maintains [this list of "good first issues"](https://github.com/facebook/react/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3A%22Component%3A+Developer+Tools%22+label%3A%22good+first+issue%22) for anyone interested in contributing to DevTools. If you see one that interests you, leave a comment!
6879

0 commit comments

Comments
 (0)