use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.NeighborPeerGroupConfigBuilder in project bgpcep by opendaylight.
the class OpenConfigMappingUtilTest method isAppNeighbor.
@Test
public void isAppNeighbor() {
assertFalse(OpenConfigMappingUtil.isApplicationPeer(new NeighborBuilder().setNeighborAddress(NEIGHBOR_ADDRESS).setConfig(new ConfigBuilder().build()).build()));
final Neighbor neighbor = new NeighborBuilder().setNeighborAddress(NEIGHBOR_ADDRESS).setConfig(new ConfigBuilder().addAugmentation(new NeighborPeerGroupConfigBuilder().setPeerGroup(OpenConfigMappingUtil.APPLICATION_PEER_GROUP_NAME).build()).build()).build();
assertTrue(OpenConfigMappingUtil.isApplicationPeer(neighbor));
}
Also used :
NeighborPeerGroupConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.NeighborPeerGroupConfigBuilder)
Neighbor(org.opendaylight.yang.gen.v1.http.openconfig.net.yang.bgp.rev151009.bgp.neighbors.Neighbor)
PeerGroupTransportConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.PeerGroupTransportConfigBuilder)
NeighborPeerGroupConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.NeighborPeerGroupConfigBuilder)
NeighborAddPathsConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.NeighborAddPathsConfigBuilder)
ConfigBuilder(org.opendaylight.yang.gen.v1.http.openconfig.net.yang.bgp.rev151009.bgp.neighbor.group.ConfigBuilder)
GlobalAddPathsConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.GlobalAddPathsConfigBuilder)
NeighborTransportConfigBuilder(org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.bgp.openconfig.extensions.rev180329.network.instance.protocol.NeighborTransportConfigBuilder)
NeighborBuilder(org.opendaylight.yang.gen.v1.http.openconfig.net.yang.bgp.rev151009.bgp.neighbors.NeighborBuilder)
Test(org.junit.Test)