DexterInstance { void checkPermission(PermissionListener listener, String permission, Thread thread) { checkSinglePermission(listener, permission, thread); } DexterInstance(Context context, AndroidPermissionService androidPermissionService,
      IntentProvider intentProvider);   }
@Test(expected = DexterException.class) public void onCheckPermissionMoreThanOnceThenThrowException() { givenPermissionIsAlreadyDenied(ANY_PERMISSION); dexter.checkPermission(permissionListener, ANY_PERMISSION, THREAD); dexter.checkPermission(permissionListener, ANY_PERMISSION, THREAD); }
@Test public void onPermissionAlreadyGrantedThenNotifiesListener() { givenPermissionIsAlreadyGranted(ANY_PERMISSION); dexter.checkPermission(permissionListener, ANY_PERMISSION, THREAD); thenPermissionIsGranted(ANY_PERMISSION); }