mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-01-13 09:00:30 +08:00
committed by
Dan Abramov
parent
d61a3313f6
commit
fd1a2441b7
@@ -1370,7 +1370,7 @@ it('renders welcome message', () => {
|
||||
All Jest matchers are [extensively documented here](http://facebook.github.io/jest/docs/en/expect.html).<br>
|
||||
Nevertheless you can use a third-party assertion library like [Chai](http://chaijs.com/) if you want to, as described below.
|
||||
|
||||
Additionally, you might find [jest-enzyme](https://github.com/blainekasten/enzyme-matchers) helpful to simplify your tests with readable matchers. The above `contains` code can be written simpler with jest-enzyme.
|
||||
Additionally, you might find [jest-enzyme](https://github.com/blainekasten/enzyme-matchers) helpful to simplify your tests with readable matchers. The above `contains` code can be written more simply with jest-enzyme.
|
||||
|
||||
```js
|
||||
expect(wrapper).toContainReact(welcome)
|
||||
|
||||
Reference in New Issue
Block a user