title: Using gradle to test android apps in an emulator
body: <p>Ok I want to use gradle to run my tests in an emulator.</p>
  
  <p>gradle has two targets that allow me to run tests:</p>
  
  <ul>
  <li>connectedCheck</li>
  <li>deviceCheck</li>
  </ul>
  
  <p>If I understood correctly, we should use deviceCheck to test stuff in an emulator, but when I run it runs no tests.</p>
  
  <p>connectedCheck also doesn't work because it can't find a device (emulators don't appear in the Android Studio the way my cell phone do).</p>
  
  <p>What I would like is (ideally):</p>
  
  <ol>
  <li>run my gradle script</li>
  <li>it boots up an emulator</li>
  <li>it runs tests on that emulator</li>
  <li>it turns down the emulator</li>
  </ol>
  
  <p>I would also like to have a target that won't boot or turn down the emulator, but it will use one if one is up.</p>
  
  <p>It's possible to do any of these things? I can't find documentation anywhere on how to configure gradle android plugin. </p>