Fix JMX generator unit test 42/49442/2
authorRobert Varga <rovarga@cisco.com>
Thu, 15 Dec 2016 16:41:31 +0000 (17:41 +0100)
committerRobert Varga <nite@hq.sk>
Mon, 19 Dec 2016 09:21:28 +0000 (09:21 +0000)
MDSAL change to use static factory methods for
instantiating well-known types has changed the way
Longs are instantiated, breaking this test. Fix it up
to reflect the change.

Change-Id: I930c04baf07005216d81cfe1e123b10b21cdc396
Signed-off-by: Robert Varga <rovarga@cisco.com>
opendaylight/config/yang-jmx-generator-plugin/src/test/java/org/opendaylight/controller/config/yangjmxgenerator/plugin/JMXGeneratorTest.java

index 583d297..e87259b 100644 (file)
@@ -386,7 +386,7 @@ public class JMXGeneratorTest extends AbstractGeneratorTest {
         visitor.assertField("private java.lang.Long maximumSize");
         visitor.assertField("private javax.management.ObjectName threadfactory");
         visitor.assertField("private java.util.concurrent.ThreadFactory threadfactoryDependency");
-        visitor.assertField("private java.lang.Long keepAlive = new java.lang.Long(\"10\")");
+        visitor.assertField("private java.lang.Long keepAlive = java.lang.Long.valueOf(\"10\")");
         visitor.assertField("private java.lang.Long coreSize");
         visitor.assertField("private byte[] binary");