@Test public void shouldConsumeAsyncMultiplePurchase() throws Exception {

    shouldStartSetup_SuccessCase();
    Purchase p1 = mock(Purchase.class);
    when(p1.getToken()).thenReturn("foo");
    when(p1.getItemType()).thenReturn(INAPP);
    Purchase p2 = mock(Purchase.class);
    when(p2.getToken()).thenReturn("bar");
    when(p2.getItemType()).thenReturn(INAPP);
    List<Purchase> purchases = new ArrayList<Purchase>();
    purchases.add(p1);
    purchases.add(p2);
    OnConsumeMultiFinishedListener listener = mock(OnConsumeMultiFinishedListener.class);
    when(service.consumePurchase(API_VERSION, Robolectric.application.getPackageName(), "foo")).thenReturn(OK.code);
    when(service.consumePurchase(API_VERSION, Robolectric.application.getPackageName(), "bar")).thenReturn(ERROR.code);
    helper.consumeAsync(purchases, listener);
    List<IabResult> results = new ArrayList<IabResult>();
    results.add(new IabResult(OK));
    results.add(new IabResult(ERROR));
    verify(listener).onConsumeMultiFinished(purchases, results);
}