Enzyme integration testing testing with react router - testing components update with links
问题 I would like to test that clicking on a link updates the components in my app. Here's my app, when you click on about it renders the About component import React, { Component } from 'react'; import './App.css'; import { MemoryRouter as Router, Route, Link } from 'react-router-dom' const Home = () => <h1>home</h1> const About = () => <h1>about</h1> class App extends Component { render() { return ( <Router> <ul> <li><Link to="/about">About</Link></li> <li><Link to="/">Home</Link></li> </ul>