@Test public void testInvokeAllOperationSuccessfulWhenQuorumSizeMet() { HashSet<Integer> hashSet = new HashSet<Integer>(); hashSet.add(123); EntryProcessorResult epr = cache1.invokeAll(hashSet, new SimpleEntryProcessor()).get(123); assertNull(epr); }
@Test(expected = EntryProcessorException.class) public void testInvokeAllOperationThrowsExceptionWhenQuorumSizeNotMet() { HashSet<Integer> hashSet = new HashSet<Integer>(); hashSet.add(123); cache4.invokeAll(hashSet, new SimpleEntryProcessor()).get(123).get(); }