X-Git-Url: https://gerrit.fd.io/r/gitweb?a=blobdiff_plain;f=v3po%2Fv3po2vpp%2Fsrc%2Ftest%2Fjava%2Fio%2Ffd%2Fhoneycomb%2Ftranslate%2Fv3po%2Finterfaces%2Facl%2Fingress%2FSubInterfaceAclCustomizerTest.java;fp=v3po%2Fv3po2vpp%2Fsrc%2Ftest%2Fjava%2Fio%2Ffd%2Fhoneycomb%2Ftranslate%2Fv3po%2Finterfaces%2FSubInterfaceAclCustomizerTest.java;h=f5ec496efa9184c6aede1d3f718ecbc7498e1dbf;hb=43485e2862128bc5fa1bee776babcda06d5510d8;hp=0492e16c8a0dae00fa6a8481b2703c2b31d590f4;hpb=99f0fde138ac6543c04e8a816bd7fc7cd64247e5;p=honeycomb.git diff --git a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/SubInterfaceAclCustomizerTest.java b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/acl/ingress/SubInterfaceAclCustomizerTest.java similarity index 92% rename from v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/SubInterfaceAclCustomizerTest.java rename to v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/acl/ingress/SubInterfaceAclCustomizerTest.java index 0492e16c8..f5ec496ef 100644 --- a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/SubInterfaceAclCustomizerTest.java +++ b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/translate/v3po/interfaces/acl/ingress/SubInterfaceAclCustomizerTest.java @@ -14,16 +14,18 @@ * limitations under the License. */ -package io.fd.honeycomb.translate.v3po.interfaces; +package io.fd.honeycomb.translate.v3po.interfaces.acl.ingress; import static org.mockito.Matchers.any; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; -import io.fd.honeycomb.translate.vpp.util.NamingContext; import io.fd.honeycomb.translate.v3po.vppclassifier.VppClassifierContextManager; +import io.fd.honeycomb.translate.vpp.util.NamingContext; import io.fd.honeycomb.translate.write.WriteFailedException; import io.fd.honeycomb.vpp.test.write.WriterCustomizerTest; +import io.fd.vpp.jvpp.core.dto.InputAclSetInterface; +import io.fd.vpp.jvpp.core.dto.InputAclSetInterfaceReply; import org.junit.Test; import org.mockito.Mock; import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.Interfaces; @@ -38,10 +40,9 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.interfaces._interface.sub.interfaces.SubInterface; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.interfaces._interface.sub.interfaces.SubInterfaceKey; import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.sub._interface.base.attributes.Acl; -import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.sub._interface.base.attributes.AclBuilder; +import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.sub._interface.base.attributes.acl.Ingress; +import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.vpp.vlan.rev150527.sub._interface.base.attributes.acl.IngressBuilder; import org.opendaylight.yangtools.yang.binding.InstanceIdentifier; -import io.fd.vpp.jvpp.core.dto.InputAclSetInterface; -import io.fd.vpp.jvpp.core.dto.InputAclSetInterfaceReply; public class SubInterfaceAclCustomizerTest extends WriterCustomizerTest { private static final String IFC_TEST_INSTANCE = "ifc-test-instance"; @@ -53,10 +54,10 @@ public class SubInterfaceAclCustomizerTest extends WriterCustomizerTest { private static final String TABLE_NAME = "table0"; private static final int TABLE_INDEX = 123; - private static final InstanceIdentifier IID = + private static final InstanceIdentifier IID = InstanceIdentifier.create(Interfaces.class).child(Interface.class, new InterfaceKey(IF_NAME)).augmentation( SubinterfaceAugmentation.class).child(SubInterfaces.class) - .child(SubInterface.class, new SubInterfaceKey(SUBIF_ID)).child(Acl.class); + .child(SubInterface.class, new SubInterfaceKey(SUBIF_ID)).child(Acl.class).child(Ingress.class); @Mock private VppClassifierContextManager classifyTableContext; @@ -103,8 +104,8 @@ public class SubInterfaceAclCustomizerTest extends WriterCustomizerTest { customizer.deleteCurrentAttributes(IID, ip4Acl(), writeContext); } - private Acl ip4Acl() { - final AclBuilder builder = new AclBuilder(); + private Ingress ip4Acl() { + final IngressBuilder builder = new IngressBuilder(); final Ip4Acl acl = new Ip4AclBuilder().setClassifyTable(TABLE_NAME).build(); builder.setIp4Acl(acl); return builder.build(); @@ -120,8 +121,8 @@ public class SubInterfaceAclCustomizerTest extends WriterCustomizerTest { return request; } - private Acl ip6Acl() { - final AclBuilder builder = new AclBuilder(); + private Ingress ip6Acl() { + final IngressBuilder builder = new IngressBuilder(); final Ip6Acl acl = new Ip6AclBuilder().setClassifyTable(TABLE_NAME).build(); builder.setIp6Acl(acl); return builder.build();