title: How to grant all android permissions in one go?
body: <p>In @Before of my espresso test I am using</p>
  
  <pre><code>if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.M) {
          getInstrumentation().getUiAutomation().executeShellCommand(
                  "pm grant " + getTargetContext().getPackageName()
                          + " android.permission.SEND_SMS");
  </code></pre>
  
  <p>Is there any way I can grant more than one permission(or all permissions) with single command only?</p>
  
  <p>Also revoking the permsission kills the app and causes test failure.Is there any workaround for that?</p>