mirror of
https://github.com/reactjs/react.dev.git
synced 2026-02-23 04:12:34 +00:00
Update 10.4-test-utils.md (#6971)
The find/scry methods which returns DOM component in react@0.13 now returns DOMElement in react@0.14 and later.
This commit is contained in:
committed by
Paul O’Shannessy
parent
070997991a
commit
23f3548578
@@ -147,12 +147,12 @@ array scryRenderedDOMComponentsWithClass(
|
||||
)
|
||||
```
|
||||
|
||||
Finds all instances of components in the rendered tree that are DOM components with the class name matching `className`.
|
||||
Finds all DOM elements of components in the rendered tree that are DOM components with the class name matching `className`.
|
||||
|
||||
### findRenderedDOMComponentWithClass
|
||||
|
||||
```javascript
|
||||
ReactComponent findRenderedDOMComponentWithClass(
|
||||
DOMElement findRenderedDOMComponentWithClass(
|
||||
ReactComponent tree,
|
||||
string className
|
||||
)
|
||||
@@ -169,12 +169,12 @@ array scryRenderedDOMComponentsWithTag(
|
||||
)
|
||||
```
|
||||
|
||||
Finds all instances of components in the rendered tree that are DOM components with the tag name matching `tagName`.
|
||||
Finds all DOM elements of components in the rendered tree that are DOM components with the tag name matching `tagName`.
|
||||
|
||||
### findRenderedDOMComponentWithTag
|
||||
|
||||
```javascript
|
||||
ReactComponent findRenderedDOMComponentWithTag(
|
||||
DOMElement findRenderedDOMComponentWithTag(
|
||||
ReactComponent tree,
|
||||
string tagName
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user