BroadcastValidationProtocol implements
    NativeProtocol<Void, ResourcePoolT> { @Override public EvaluationStatus evaluate(int round, ResourcePoolT resourcePool, Network network) { if (resourcePool.getNoOfParties() <= 2) { return EvaluationStatus.IS_DONE; } if (round == 0) { broadcast = new SecureBroadcastUtil(network); digest = broadcast.computeAndSendDigests(input); return EvaluationStatus.HAS_MORE_ROUNDS; } else { broadcast.receiveAndValidateDigests(digest); return EvaluationStatus.IS_DONE; } } BroadcastValidationProtocol(List<byte[]> input);  BroadcastValidationProtocol(byte[] input); @Override Void out(); @Override EvaluationStatus evaluate(int round, ResourcePoolT resourcePool, Network network);  }
@Test public void testEvaluateWithTwoPartiesReturnsDone() { EvaluationStatus status = new BroadcastValidationProtocol<>(new byte[1]) .evaluate(0, new ResourcePool() { @Override public int getMyId() { return 0; } @Override public int getNoOfParties() { return 2; } }, null); Assert.assertEquals(EvaluationStatus.IS_DONE, status); }