diff options
author | Marek Gradzki <mgradzki@cisco.com> | 2016-05-26 14:52:20 +0200 |
---|---|---|
committer | Marek Gradzki <mgradzki@cisco.com> | 2016-05-30 07:20:40 +0200 |
commit | 3c15fa224a914aa9e03ae2e97fab1e740a0f8b04 (patch) | |
tree | b3b93894ac36b4d143f10337421777a7cfb78ef3 /v3po/v3po2vpp/src/test/java/io | |
parent | fc4f291590e29f7d576793041ece4081d28c0027 (diff) |
Fix vlan type handling for sub interfaces and vlan-tag-rewrite operation
Change-Id: I932fb63932d9c53acc6317fa77cc0683faf47081
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Diffstat (limited to 'v3po/v3po2vpp/src/test/java/io')
3 files changed, 4 insertions, 2 deletions
diff --git a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfaces/SubInterfaceCustomizerTest.java b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfaces/SubInterfaceCustomizerTest.java index 31ab3aab5..0b4279126 100644 --- a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfaces/SubInterfaceCustomizerTest.java +++ b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfaces/SubInterfaceCustomizerTest.java @@ -79,7 +79,7 @@ public class SubInterfaceCustomizerTest { private SubInterface generateSubInterface(final String superIfName) { SubInterfaceBuilder builder = new SubInterfaceBuilder(); - builder.setVlanType(VlanType._802dot1q); + builder.setVlanType(VlanType._802dot1ad); builder.setIdentifier(11L); builder.setNumberOfTags((short)1); builder.setOuterId(new VlanTag(100)); diff --git a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/SubInterfaceCustomizerTest.java b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/SubInterfaceCustomizerTest.java index 4f6857b47..0addcee58 100644 --- a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/SubInterfaceCustomizerTest.java +++ b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/SubInterfaceCustomizerTest.java @@ -101,6 +101,7 @@ public class SubInterfaceCustomizerTest extends ChildReaderCustomizerTest<SubInt final SwInterfaceDetails ifaceDetails = new SwInterfaceDetails(); ifaceDetails.subId = ifId; ifaceDetails.interfaceName = ifName.getBytes(); + ifaceDetails.subDot1Ad = 1; cachedInterfaceDump.put(ifId, ifaceDetails); cache.put(InterfaceCustomizer.DUMPED_IFCS_CONTEXT_KEY, cachedInterfaceDump); diff --git a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/VlanTagRewriteCustomizerTest.java b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/VlanTagRewriteCustomizerTest.java index 4173eba3c..78c9e266e 100644 --- a/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/VlanTagRewriteCustomizerTest.java +++ b/v3po/v3po2vpp/src/test/java/io/fd/honeycomb/v3po/translate/v3po/interfacesstate/VlanTagRewriteCustomizerTest.java @@ -86,13 +86,14 @@ public class VlanTagRewriteCustomizerTest extends ChildReaderCustomizerTest<Vlan final SwInterfaceDetails ifaceDetails = new SwInterfaceDetails(); ifaceDetails.subId = ifId; ifaceDetails.interfaceName = ifName.getBytes(); + ifaceDetails.vtrPushDot1Q = 1; cachedInterfaceDump.put(ifId, ifaceDetails); cache.put(InterfaceCustomizer.DUMPED_IFCS_CONTEXT_KEY, cachedInterfaceDump); final VlanTagRewriteBuilder builder = mock(VlanTagRewriteBuilder.class); getCustomizer().readCurrentAttributes(getVlanTagRewriteId(ifName), builder, ctx); - verify(builder).setFirstPushed(VlanType._802dot1ad); + verify(builder).setFirstPushed(VlanType._802dot1q); verify(builder).setRewriteOperation(TagRewriteOperation.Disabled); verify(builder, never()).setTag1(any()); verify(builder, never()).setTag2(any()); |