I want to check with jest if the following svg path element contains the attribute d
<path id="TrendLine" fill="none" stroke="black" d="M170,28.76363636363638C170,28.76363636363638,221.46221083573664,189.150059910"></path>
How do I use jest to search for specific attribute in an element?
相关问题
- How to toggle on Order in ReactJS
- Refreshing page gives Cannot GET /page_url in reac
- Adding a timeout to a render function in ReactJS
- React Native Inline style for multiple Text in sin
- Issue with React.PropTypes.func.isRequired
相关文章
- Why would we use useEffect without a dependency ar
- Is it possible to get ref of props.children?
- Stateless function components cannot be given refs
- React testing library: Test attribute / prop
- React/JestJS/Enzyme: How to test for ref function?
- Material-UI [v0.x] RaisedButton on hover styles
- Remove expo from react native
- ReactJS toLowerCase is not a function
You can use enzyme's shallow method to render your component and then to check the props on the path element: