title: Mocking multiple API calls in my class and writing a test
body: <p>So, I am trying to mock some API's in my class, the code looks something like this.</p>
  
  <pre><code>import requests
  class myclass:
    def A(self, data):
      response = requests.get("some_url", params)
      if response.data["has_value"]:
        new_response = requests.get("some_url", params)
        **do some validation on data recieved**
    def B(self, data):
      response = requests.get("some_url", params)
      **do some validation on data recieved**
    def _run(self):
      **some code**
      self.A(data)
      self.B(data)
  
  m = myclass()
  m.run()
  </code></pre>
  
  <p>I am trying to test for these and need some help with it. while doing validations we change some fields in data, and I have to verify if the data is correct. how can this be done?
  Thank you.</p>