X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fconfig%2Fyang-jmx-generator-plugin%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fconfig%2Fyangjmxgenerator%2Fplugin%2Fmodule%2FAbstractGeneratedObjectTest.java;fp=opendaylight%2Fconfig%2Fyang-jmx-generator-plugin%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fconfig%2Fyangjmxgenerator%2Fplugin%2Fmodule%2FAbstractGeneratedObjectTest.java;h=0000000000000000000000000000000000000000;hb=ac6f2699cd0c1e340cc32e8f0d0ca94c8e9c0cc0;hp=34b38bfa50572db2b36d82eada4193c22a4192b7;hpb=f43b01b81319959b1907e3e04537f5169e7f33d8;p=controller.git diff --git a/opendaylight/config/yang-jmx-generator-plugin/src/test/java/org/opendaylight/controller/config/yangjmxgenerator/plugin/module/AbstractGeneratedObjectTest.java b/opendaylight/config/yang-jmx-generator-plugin/src/test/java/org/opendaylight/controller/config/yangjmxgenerator/plugin/module/AbstractGeneratedObjectTest.java deleted file mode 100644 index 34b38bfa50..0000000000 --- a/opendaylight/config/yang-jmx-generator-plugin/src/test/java/org/opendaylight/controller/config/yangjmxgenerator/plugin/module/AbstractGeneratedObjectTest.java +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0 which accompanies this distribution, - * and is available at http://www.eclipse.org/legal/epl-v10.html - */ - -package org.opendaylight.controller.config.yangjmxgenerator.plugin.module; - -import static org.junit.Assert.assertNotNull; -import static org.junit.Assert.assertTrue; - -import com.google.common.io.Files; -import java.io.File; -import java.io.FileReader; -import java.io.IOException; -import java.nio.charset.StandardCharsets; -import net.sourceforge.pmd.lang.Parser; -import net.sourceforge.pmd.lang.ParserOptions; -import net.sourceforge.pmd.lang.ast.Node; -import net.sourceforge.pmd.lang.java.Java17Parser; -import org.opendaylight.controller.config.yangjmxgenerator.plugin.AbstractGeneratorTest; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - -public class AbstractGeneratedObjectTest extends AbstractGeneratorTest { - private static final Logger LOG = LoggerFactory.getLogger(AbstractGeneratedObjectTest.class); - - protected void assertHasMethodNamed(Node c, String method) { - assertTrue(c.hasDescendantMatchingXPath("//MethodDeclaration[MethodDeclarator[@Image='" + - method + - "']]")); - } - - protected Node parse(File dstFile) throws IOException { - assertNotNull(dstFile); - LOG.debug(Files.toString(dstFile, StandardCharsets.UTF_8)); - Parser parser = new Java17Parser(new ParserOptions()); - return parser.parse(dstFile.toString(), new FileReader(dstFile)); - } - - -}