title: How to mock JSONObject?
body: <p>In the middle of a method I'm doing something like this</p>
  
  <pre><code>JSONObject = new JSONObject(json);
  </code></pre>
  
  <p>Now I'm trying to unit test that using <code>Android Studio</code> and <code>JUnit</code>. Unfortunately, Android Studio won't let me create a real <code>JSONObject</code> instance and ask me to mock it.</p>
  
  <p>What's the simplest way to keep that code and being able to unit test?</p>
  
  <p><code>Mockito</code> won't help me since it's not able to mock constructors, but it seems <code>PowerMock</code> is the way to go.</p>