diff options
author | 2016-09-23 09:06:19 +0200 | |
---|---|---|
committer | 2016-09-26 08:15:38 +0200 | |
commit | 0cfdff5e57bd6357acc64debf0ee49c9455a24d7 (patch) | |
tree | 54f14153077acb811212c0ba7293d894ffca7596 /vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read | |
parent | 60d69218642cc976fa606fd8a38623d8c035dd86 (diff) |
HONEYCOMB-116: utility for stubbing MappingContext methods
- introduces MappingContextHelper (refactored ContextTestUtils)
- updates all v3po and lisp unit tests to use MCH
- updates lisp tests to mock EidMappingContext
Change-Id: I73b1adda767db71388ca1c4d7206cfd7ee9c70e1
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Diffstat (limited to 'vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read')
-rw-r--r-- | vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read/ReaderCustomizerTest.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read/ReaderCustomizerTest.java b/vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read/ReaderCustomizerTest.java index 3637ee2c8..c90504264 100644 --- a/vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read/ReaderCustomizerTest.java +++ b/vpp-common/vpp-translate-test/src/main/java/io/fd/honeycomb/vpp/test/read/ReaderCustomizerTest.java @@ -25,6 +25,7 @@ import io.fd.honeycomb.translate.spi.read.ReaderCustomizer; import io.fd.honeycomb.translate.read.ReadContext; import io.fd.honeycomb.translate.spi.read.ReaderCustomizer; import io.fd.honeycomb.vpp.test.util.FutureProducer; +import io.fd.honeycomb.vpp.test.util.NamingContextHelper; import org.junit.Before; import org.junit.Test; import org.mockito.Mock; @@ -41,7 +42,8 @@ import org.openvpp.jvpp.core.future.FutureJVppCore; * @param <D> Specific DataObject derived type (Identifiable), that is handled by this customizer * @param <B> Specific Builder for handled type (D) */ -public abstract class ReaderCustomizerTest<D extends DataObject, B extends Builder<D>> implements FutureProducer { +public abstract class ReaderCustomizerTest<D extends DataObject, B extends Builder<D>> implements FutureProducer, + NamingContextHelper { @Mock protected FutureJVppCore api; @@ -52,7 +54,7 @@ public abstract class ReaderCustomizerTest<D extends DataObject, B extends Build protected ModificationCache cache; protected final Class<D> dataObjectClass; - private ReaderCustomizer<D, B> customizer; + protected ReaderCustomizer<D, B> customizer; protected ReaderCustomizerTest(Class<D> dataObjectClass) { this.dataObjectClass = dataObjectClass; |