title: Mock Axios multiple requests
body: <p>So i bumped into this problem where i have 4 to 5 API calls sent in <code>componentDidMount</code> and i want to mock the response for some to test scenarios. This is how my <code>componentDidMount</code> look like</p>
  
  <pre><code>  this.updateTokenHOC(this.getCommentsData)
    this.updateTokenHOC(this.checkReviewer)
    this.updateTokenHOC(this.getStepDataFromServer,1)
    this.updateTokenHOC(this.getStepDataFromServer,2)
    this.updateTokenHOC(this.getStepDataFromServer,3)
    this.updateTokenHOC(this.getStepDataFromServer,4)
    this.updateTokenHOC(this.getStepDataFromServer,5)
  </code></pre>
  
  <p>Yup these all are API calls.
  I have tried with <a href="https://github.com/ctimmerm/axios-mock-adapter" rel="nofollow noreferrer">axios-mock-adapter</a> where i mock with <code>URL</code>,<code>Regex</code> requests.When i make axios call from testing environment it gives me mock response. but these calls change the state and that i dont find in my state.</p>
  
  <p>The testing fail to mock this call. as you can see for debugging i made test property in state</p>
  
  <pre><code>  getCommentsData(config) {
  const type = this.state.viewType
  const id = this.state.requestId
  instance.get(`/review/sections?request_id=${id}&amp;request_type=${type}`, config)
    .then((response) =&gt; {
      this.setState({test:'iam in comments data'})
      if (response.status === 200) {
        for (let step in response.data.sections) {
          if (response.data.sections[step].section_type === 'device_quota') {
            this.setState({
              ...this.state,
              steps: {
                ...this.state.steps,
                step1: {
                  ...this.state.steps.step1,
                  comments: response.data.sections[step].comments,
                },
              }
            })
          }
  </code></pre>
  
  <p>The alternative solution can be if i can test this method separately like in enzyme  wrapper.find('ViewReview').instance() but have not succeeded with that aswell. </p>
  
  <p>P.S i have tried <a href="https://github.com/nock/nock" rel="nofollow noreferrer">Nock</a>, <a href="https://www.npmjs.com/package/jest-mock-axios" rel="nofollow noreferrer">Jest-axios-mock</a> (this works but for multiple requests i cannot mock response for all),moxios</p>