summaryrefslogtreecommitdiffstats
path: root/infra/translate-impl/src/test
diff options
context:
space:
mode:
authorJan Srnicek <jsrnicek@cisco.com>2017-02-07 09:33:38 +0100
committerJan Srnicek <jsrnicek@cisco.com>2017-02-07 09:33:38 +0100
commit8450b69800c827ba221351eb0c374fcbd9146593 (patch)
tree8b53ec074196bedd2b4012d69dda60fb756bfa64 /infra/translate-impl/src/test
parent92afaeb4a959ea5a6a072fe3ed7a01088d703e0b (diff)
Prevent submitting of structural reader for list node
Static customizer must be provided instead till HONEYCOMB-344 is resolved Change-Id: Id71f69fe23b156e6de10eed06a3596de8e602bbe Signed-off-by: Jan Srnicek <jsrnicek@cisco.com>
Diffstat (limited to 'infra/translate-impl/src/test')
-rw-r--r--infra/translate-impl/src/test/java/io/fd/honeycomb/translate/impl/read/registry/CompositeReaderRegistryBuilderTest.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/infra/translate-impl/src/test/java/io/fd/honeycomb/translate/impl/read/registry/CompositeReaderRegistryBuilderTest.java b/infra/translate-impl/src/test/java/io/fd/honeycomb/translate/impl/read/registry/CompositeReaderRegistryBuilderTest.java
index 4dee8e60f..0c7c71eac 100644
--- a/infra/translate-impl/src/test/java/io/fd/honeycomb/translate/impl/read/registry/CompositeReaderRegistryBuilderTest.java
+++ b/infra/translate-impl/src/test/java/io/fd/honeycomb/translate/impl/read/registry/CompositeReaderRegistryBuilderTest.java
@@ -66,6 +66,11 @@ public class CompositeReaderRegistryBuilderTest {
return mock;
}
+ @Test(expected = IllegalArgumentException.class)
+ public void testPreventStructuralReaderForList() {
+ new CompositeReaderRegistryBuilder().addStructuralReader(InstanceIdentifier.create(DataObjects.DataObjectK.class), DataObjects.DataObjectKBuilder.class);
+ }
+
@Test
public void testCompositeStructure() throws Exception {
final CompositeReaderRegistryBuilder compositeReaderRegistryBuilder = new CompositeReaderRegistryBuilder();