X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-binding-broker%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fsal%2Fbinding%2Ftest%2Fbugfix%2FUnionSerializationTest.java;h=9f8a443bbf7e37400683736c64d2a08fad2f13f8;hp=36a172d09c3f1a99bee21586f9a2b47c75103d9f;hb=1ee71ae58a03de1c1f8fd8c789e7921508ba9f59;hpb=12204729ecaa1d1862a580cc6282eceacd21efe2 diff --git a/opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/sal/binding/test/bugfix/UnionSerializationTest.java b/opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/sal/binding/test/bugfix/UnionSerializationTest.java index 36a172d09c..9f8a443bbf 100644 --- a/opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/sal/binding/test/bugfix/UnionSerializationTest.java +++ b/opendaylight/md-sal/sal-binding-broker/src/test/java/org/opendaylight/controller/sal/binding/test/bugfix/UnionSerializationTest.java @@ -19,22 +19,22 @@ import org.opendaylight.yang.gen.v1.urn.tbd.params.xml.ns.yang.nt.l3.unicast.igp import org.opendaylight.yangtools.yang.data.api.CompositeNode; public class UnionSerializationTest extends AbstractDataServiceTest { - + public static final String PREFIX_STRING = "192.168.0.1/32"; - - + + @Test public void testPrefixSerialization() throws Exception { - + Ipv4Prefix ipv4prefix = new Ipv4Prefix(PREFIX_STRING); IpPrefix ipPrefix = new IpPrefix(ipv4prefix); Prefix prefix = new PrefixBuilder().setPrefix(ipPrefix).build(); - + CompositeNode serialized = testContext.getBindingToDomMappingService().toDataDom(prefix); assertNotNull(serialized); assertNotNull(serialized.getFirstSimpleByName(Prefix.QNAME)); assertEquals(PREFIX_STRING, serialized.getFirstSimpleByName(Prefix.QNAME).getValue()); - + Prefix deserialized = (Prefix) testContext.getBindingToDomMappingService().dataObjectFromDataDom(Prefix.class, serialized); assertNotNull(deserialized); assertNotNull(deserialized.getPrefix());