use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.unreach.destination.object.unreach.destination.obj.Destination in project openflowplugin by opendaylight.
the class MatchNormalizationUtilTest method normalizeIpv4Match.
@Test
public void normalizeIpv4Match() {
final String source = "192.168.1.2/24";
final String destination = "192.168.2.2/24";
final MatchBuilder matchBuilder = MatchNormalizationUtil.normalizeIpv4Match(new MatchBuilder().setLayer3Match(new Ipv4MatchBuilder().setIpv4Source(new Ipv4Prefix(source)).setIpv4Destination(new Ipv4Prefix(destination)).build()));
assertEquals("192.168.1.0/24", Ipv4Match.class.cast(matchBuilder.getLayer3Match()).getIpv4Source().getValue());
assertEquals("192.168.2.0/24", Ipv4Match.class.cast(matchBuilder.getLayer3Match()).getIpv4Destination().getValue());
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.unreach.destination.object.unreach.destination.obj.Destination in project openflowplugin by opendaylight.
the class MatchNormalizationUtilTest method normalizeArpMatch.
@Test
public void normalizeArpMatch() {
final int arpOp = 10;
final String source = "192.168.1.2/24";
final String destination = "192.168.2.2/24";
final MacAddress sourceHw = new MacAddress("01:23:45:AB:CD:EF");
final MacAddress dstHw = new MacAddress("01:23:45:AB:C0:EF");
final MacAddress mask = new MacAddress("FF:FF:FF:FF:FF:FF");
final MatchBuilder matchBuilder = MatchNormalizationUtil.normalizeArpMatch(new MatchBuilder().setLayer3Match(new ArpMatchBuilder().setArpOp(10).setArpSourceTransportAddress(new Ipv4Prefix(source)).setArpTargetTransportAddress(new Ipv4Prefix(destination)).setArpTargetHardwareAddress(new ArpTargetHardwareAddressBuilder().setAddress(dstHw).setMask(mask).build()).setArpSourceHardwareAddress(new ArpSourceHardwareAddressBuilder().setAddress(sourceHw).setMask(mask).build()).build()));
assertEquals(arpOp, ArpMatch.class.cast(matchBuilder.getLayer3Match()).getArpOp().intValue());
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.unreach.destination.object.unreach.destination.obj.Destination in project openflowplugin by opendaylight.
the class MatchNormalizationUtilTest method normalizeTunnelIpv4Match.
@Test
public void normalizeTunnelIpv4Match() {
final String source = "192.168.1.2/24";
final String destination = "192.168.2.2/24";
final MatchBuilder matchBuilder = MatchNormalizationUtil.normalizeTunnelIpv4Match(new MatchBuilder().setLayer3Match(new TunnelIpv4MatchBuilder().setTunnelIpv4Source(new Ipv4Prefix(source)).setTunnelIpv4Destination(new Ipv4Prefix(destination)).build()));
assertEquals("192.168.1.0/24", TunnelIpv4Match.class.cast(matchBuilder.getLayer3Match()).getTunnelIpv4Source().getValue());
assertEquals("192.168.2.0/24", TunnelIpv4Match.class.cast(matchBuilder.getLayer3Match()).getTunnelIpv4Destination().getValue());
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.unreach.destination.object.unreach.destination.obj.Destination in project openflowplugin by opendaylight.
the class MatchV10ResponseConvertorTest method testUdpMatch.
/**
* UDP match test for {@link MatchV10ResponseConvertor#convert(MatchV10, VersionDatapathIdConvertorData)}.
*/
@Test
public void testUdpMatch() {
// TP_SRC, TP_DST are wildcarded.
// NW_PROTO is not wildcarded but null.
Long dlType = 0x800L;
FlowWildcardsV10 wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, true, true);
MatchV10Builder builder = new MatchV10Builder().setWildcards(wc).setDlType(dlType.intValue());
MatchV10 match = builder.build();
BigInteger dpid = BigInteger.valueOf(12345L);
final VersionDatapathIdConvertorData datapathIdConvertorData = new VersionDatapathIdConvertorData(OFConstants.OFP_VERSION_1_0);
datapathIdConvertorData.setDatapathId(dpid);
Match salMatch = convert(match, datapathIdConvertorData).build();
EthernetMatch etherMatch = salMatch.getEthernetMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong IP match", null, salMatch.getIpMatch());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify UDP protocol.
Short ipProto = 17;
match = builder.setNwProto(ipProto).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
IpMatch ipMatch = salMatch.getIpMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// TP_SRC is not wildcarded but null.
wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, true, false);
match = builder.setWildcards(wc).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify UDP source port.
Integer srcPort = 60000;
match = builder.setTpSrc(srcPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
UdpMatch udpMatch = (UdpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong UDP src", srcPort, udpMatch.getUdpSourcePort().getValue());
Assert.assertEquals("Wrong UDP dst", null, udpMatch.getUdpDestinationPort());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// TP_DST is not wildcarded but null.
wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, false, false);
match = builder.setWildcards(wc).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
udpMatch = (UdpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong UDP src", srcPort, udpMatch.getUdpSourcePort().getValue());
Assert.assertEquals("Wrong UDP dst", null, udpMatch.getUdpDestinationPort());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify UDP destination port only.
Integer dstPort = 6653;
match = builder.setTpSrc(null).setTpDst(dstPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
udpMatch = (UdpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong UDP src", null, udpMatch.getUdpSourcePort());
Assert.assertEquals("Wrong UDP dst", dstPort, udpMatch.getUdpDestinationPort().getValue());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify both source and destination port.
srcPort = 32767;
dstPort = 9999;
match = builder.setTpSrc(srcPort).setTpDst(dstPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
udpMatch = (UdpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong UDP src", srcPort, udpMatch.getUdpSourcePort().getValue());
Assert.assertEquals("Wrong UDP dst", dstPort, udpMatch.getUdpDestinationPort().getValue());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
}
use of org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.pcep.types.rev181109.unreach.destination.object.unreach.destination.obj.Destination in project openflowplugin by opendaylight.
the class MatchV10ResponseConvertorTest method testTcpMatch.
/**
* TCP match test for {@link MatchV10ResponseConvertor#convert(MatchV10, VersionDatapathIdConvertorData)}.
*/
@Test
public void testTcpMatch() {
// TP_SRC, TP_DST are wildcarded.
// NW_PROTO is not wildcarded but null.
Long dlType = 0x800L;
FlowWildcardsV10 wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, true, true);
MatchV10Builder builder = new MatchV10Builder().setWildcards(wc).setDlType(dlType.intValue());
MatchV10 match = builder.build();
BigInteger dpid = BigInteger.valueOf(12345L);
final VersionDatapathIdConvertorData datapathIdConvertorData = new VersionDatapathIdConvertorData(OFConstants.OFP_VERSION_1_0);
datapathIdConvertorData.setDatapathId(dpid);
Match salMatch = convert(match, datapathIdConvertorData).build();
EthernetMatch etherMatch = salMatch.getEthernetMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong IP match", null, salMatch.getIpMatch());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify TCP protocol.
Short ipProto = 6;
match = builder.setNwProto(ipProto).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
IpMatch ipMatch = salMatch.getIpMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// TP_SRC is not wildcarded but null.
wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, true, false);
match = builder.setWildcards(wc).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong L4 match", null, salMatch.getLayer4Match());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify TCP source port.
Integer srcPort = 60000;
match = builder.setTpSrc(srcPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
TcpMatch tcpMatch = (TcpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong TCP src", srcPort, tcpMatch.getTcpSourcePort().getValue());
Assert.assertEquals("Wrong TCP dst", null, tcpMatch.getTcpDestinationPort());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// TP_DST is not wildcarded but null.
wc = new FlowWildcardsV10(true, true, false, true, true, true, false, true, false, false);
match = builder.setWildcards(wc).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
tcpMatch = (TcpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong TCP src", srcPort, tcpMatch.getTcpSourcePort().getValue());
Assert.assertEquals("Wrong TCP dst", null, tcpMatch.getTcpDestinationPort());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify TCP destination port only.
Integer dstPort = 6653;
match = builder.setTpSrc(null).setTpDst(dstPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
tcpMatch = (TcpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong TCP src", null, tcpMatch.getTcpSourcePort());
Assert.assertEquals("Wrong TCP dst", dstPort, tcpMatch.getTcpDestinationPort().getValue());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
// Specify both source and destination port.
srcPort = 32767;
dstPort = 9999;
match = builder.setTpSrc(srcPort).setTpDst(dstPort).build();
salMatch = convert(match, datapathIdConvertorData).build();
etherMatch = salMatch.getEthernetMatch();
ipMatch = salMatch.getIpMatch();
tcpMatch = (TcpMatch) salMatch.getLayer4Match();
Assert.assertEquals("Wrong in port", null, salMatch.getInPort());
Assert.assertEquals("Wrong dl src", null, etherMatch.getEthernetSource());
Assert.assertEquals("Wrong dl dst", null, etherMatch.getEthernetDestination());
Assert.assertEquals("Wrong dl type", dlType, etherMatch.getEthernetType().getType().getValue());
Assert.assertEquals("Wrong VLAN match", null, salMatch.getVlanMatch());
Assert.assertEquals("Wrong ip protocol", ipProto, ipMatch.getIpProtocol());
Assert.assertEquals("Wrong ip proto", null, ipMatch.getIpProto());
Assert.assertEquals("Wrong ip ecn", null, ipMatch.getIpEcn());
Assert.assertEquals("Wrong ip dscp", null, ipMatch.getIpDscp());
Assert.assertEquals("Wrong L3 match", null, salMatch.getLayer3Match());
Assert.assertEquals("Wrong TCP src", srcPort, tcpMatch.getTcpSourcePort().getValue());
Assert.assertEquals("Wrong TCP dst", dstPort, tcpMatch.getTcpDestinationPort().getValue());
Assert.assertEquals("Wrong ICMPv4 match", null, salMatch.getIcmpv4Match());
}
Aggregations