You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
expect(submitButton).toBeNull() // it doesn't exist
564
565
```
565
566
567
+
## `queryAll` and `getAll` APIs
568
+
569
+
Each of the `query` APIs have a corresponsing `queryAll` version that always returns an Array of matching nodes. `getAll` is the same but throws when the array has a length of 0.
570
+
571
+
```javascript
572
+
constsubmitButtons=queryAllByText('submit')
573
+
expect(submitButtons).toHaveLength(3) // expect 3 elements
574
+
expect(submitButtons[0]).toBeInTheDOM()
575
+
```
576
+
566
577
## Examples
567
578
568
579
You'll find examples of testing with different libraries in
0 commit comments