X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fcds-access-api%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Faccess%2Fconcepts%2FAbstractIdentifierTest.java;h=080e1e46b4854a74615e1ac8d9a08bd3066cb01c;hp=34ce489793a1f2f1190944ed18610bbfd71abcb8;hb=refs%2Fchanges%2F59%2F47459%2F4;hpb=97542f208267cb5392fc8c8d9baf6c1d3ee4ae32 diff --git a/opendaylight/md-sal/cds-access-api/src/test/java/org/opendaylight/controller/cluster/access/concepts/AbstractIdentifierTest.java b/opendaylight/md-sal/cds-access-api/src/test/java/org/opendaylight/controller/cluster/access/concepts/AbstractIdentifierTest.java index 34ce489793..080e1e46b4 100644 --- a/opendaylight/md-sal/cds-access-api/src/test/java/org/opendaylight/controller/cluster/access/concepts/AbstractIdentifierTest.java +++ b/opendaylight/md-sal/cds-access-api/src/test/java/org/opendaylight/controller/cluster/access/concepts/AbstractIdentifierTest.java @@ -10,6 +10,7 @@ package org.opendaylight.controller.cluster.access.concepts; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; + import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.IOException; @@ -20,7 +21,9 @@ import org.opendaylight.yangtools.concepts.Identifier; public abstract class AbstractIdentifierTest { abstract T object(); + abstract T differentObject(); + abstract T equalObject(); @Test @@ -38,10 +41,10 @@ public abstract class AbstractIdentifierTest { } @SuppressWarnings("unchecked") - private static T copy(T o) throws IOException, ClassNotFoundException { + private static T copy(T obj) throws IOException, ClassNotFoundException { final ByteArrayOutputStream bos = new ByteArrayOutputStream(); try (ObjectOutputStream oos = new ObjectOutputStream(bos)) { - oos.writeObject(o); + oos.writeObject(obj); } try (ObjectInputStream ois = new ObjectInputStream(new ByteArrayInputStream(bos.toByteArray()))) {