The main purpose is to test the interaction between react front-end and service side.
React Test Intends to Use enzyme
Fake XMLHttpRequest is not particularly familiar with, and plans to use sinon.js
However, enzyme seems to cooperate better with mocha, and I don’t know what better experience you have.
The interaction with the service side is divided into two parts:
1. To ensure the correctness of the interface, this should be the work of api Interface testing
2. Ensure that the data returned by the back end can be displayed correctly. This part is e2e test. You can add selenium with nightwatch or add some assertion libraries with Puppet.