@Test public void testAssemblePeerEndpoint() throws Exception { final PeerEndpoint peerEndpoint = createPeer(ADDRESS_1, CONTEXT_ID_1); final List<UnconfiguredPeerEndpoint> gatheredPeers = StatusUtil.assemblePeerEndpoint(Stream.of(peerEndpoint), null); Assert.assertEquals(1, gatheredPeers.size()); final UnconfiguredPeerEndpoint actual = gatheredPeers.get(0); compareEPs(peerEndpoint, actual); Assert.assertTrue(actual.getUnconfiguredRuleGroup().isEmpty()); }
@VisibleForTesting static List<UnconfiguredPeerEndpoint> assemblePeerEndpoint(final Stream<PeerEndpoint> peerEndpoint, final PolicyConfigurationContext context) { return peerEndpoint .map((peerEP) -> new UnconfiguredPeerEndpointBuilder(peerEP) .setUnconfiguredRuleGroup( assembleRuleGroups(peerEP.getRuleGroupWithRendererEndpointParticipation().stream(), context) ).build()) .collect(Collectors.toList()); }
StatusUtil { @VisibleForTesting static List<UnconfiguredPeerEndpoint> assemblePeerEndpoint(final Stream<PeerEndpoint> peerEndpoint, final PolicyConfigurationContext context) { return peerEndpoint .map((peerEP) -> new UnconfiguredPeerEndpointBuilder(peerEP) .setUnconfiguredRuleGroup( assembleRuleGroups(peerEP.getRuleGroupWithRendererEndpointParticipation().stream(), context) ).build()) .collect(Collectors.toList()); } }
StatusUtil { @VisibleForTesting static List<UnconfiguredPeerEndpoint> assemblePeerEndpoint(final Stream<PeerEndpoint> peerEndpoint, final PolicyConfigurationContext context) { return peerEndpoint .map((peerEP) -> new UnconfiguredPeerEndpointBuilder(peerEP) .setUnconfiguredRuleGroup( assembleRuleGroups(peerEP.getRuleGroupWithRendererEndpointParticipation().stream(), context) ).build()) .collect(Collectors.toList()); } private  StatusUtil(); }
StatusUtil { @VisibleForTesting static List<UnconfiguredPeerEndpoint> assemblePeerEndpoint(final Stream<PeerEndpoint> peerEndpoint, final PolicyConfigurationContext context) { return peerEndpoint .map((peerEP) -> new UnconfiguredPeerEndpointBuilder(peerEP) .setUnconfiguredRuleGroup( assembleRuleGroups(peerEP.getRuleGroupWithRendererEndpointParticipation().stream(), context) ).build()) .collect(Collectors.toList()); } private  StatusUtil(); static UnconfiguredRendererEndpoint assembleFullyNotConfigurableRendererEP(final PolicyConfigurationContext context,
                                                                                      final String info); static UnconfiguredRendererEndpoint assembleNotConfigurableRendererEPForPeer(final PolicyConfigurationContext context,
                                                                                        final PeerEndpoint peerEndpoint,
                                                                                        final String info); }
StatusUtil { @VisibleForTesting static List<UnconfiguredPeerEndpoint> assemblePeerEndpoint(final Stream<PeerEndpoint> peerEndpoint, final PolicyConfigurationContext context) { return peerEndpoint .map((peerEP) -> new UnconfiguredPeerEndpointBuilder(peerEP) .setUnconfiguredRuleGroup( assembleRuleGroups(peerEP.getRuleGroupWithRendererEndpointParticipation().stream(), context) ).build()) .collect(Collectors.toList()); } private  StatusUtil(); static UnconfiguredRendererEndpoint assembleFullyNotConfigurableRendererEP(final PolicyConfigurationContext context,
                                                                                      final String info); static UnconfiguredRendererEndpoint assembleNotConfigurableRendererEPForPeer(final PolicyConfigurationContext context,
                                                                                        final PeerEndpoint peerEndpoint,
                                                                                        final String info);  }