BUG-4369: remove dependency on MDSAL components 49/29649/2
authorRobert Varga <rovarga@cisco.com>
Fri, 13 Nov 2015 13:51:51 +0000 (14:51 +0100)
committerRobert Varga <robert.varga@pantheon.sk>
Mon, 16 Nov 2015 23:32:34 +0000 (00:32 +0100)
This removes the single integration test which required the API plugin
and eradicates all mentions of the mdsal project in yangtools.

Change-Id: I04d9d864b6dd0da5e4dc7829d975cf73707b5605
Signed-off-by: Robert Varga <rovarga@cisco.com>
common/parent/pom.xml
yang/yang-maven-plugin-it/src/test/java/org/opendaylight/yangtools/yang2sources/plugin/it/YangToSourcesPluginTestIT.java
yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/pom.xml [deleted file]
yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/src/main/yang/test.yang [deleted file]
yang/yang-model-parent/pom.xml [deleted file]

index e01ad2d7651863560fce2e31d26b57e157f4c948..48b0727aff2cb469379312e37076f132e24f46f3 100644 (file)
                             </goals>
                             <configuration>
                                 <yangFilesRootDir>src/main/yang</yangFilesRootDir>
-                                <codeGenerators>
-                                    <generator>
-                                        <codeGeneratorClass>
-                                            org.opendaylight.yangtools.maven.sal.api.gen.plugin.CodeGeneratorImpl
-                                        </codeGeneratorClass>
-                                        <outputBaseDir>
-                                            target/generated-sources/sal
-                                        </outputBaseDir>
-                                    </generator>
-                                    <generator>
-                                        <codeGeneratorClass>org.opendaylight.yangtools.yang.unified.doc.generator.maven.DocumentationGeneratorImpl</codeGeneratorClass>
-                                        <outputBaseDir>target/site/restconf</outputBaseDir>
-                                    </generator>
-                                    <generator>
-                                        <codeGeneratorClass>org.opendaylight.yangtools.yang.wadl.generator.maven.WadlGenerator</codeGeneratorClass>
-                                        <outputBaseDir>target/site/restconf</outputBaseDir>
-                                    </generator>
-                                </codeGenerators>
                                 <inspectDependencies>true</inspectDependencies>
                             </configuration>
                         </execution>
                     </executions>
-                    <dependencies>
-                        <dependency>
-                            <groupId>org.opendaylight.mdsal</groupId>
-                            <artifactId>maven-sal-api-gen-plugin</artifactId>
-                            <version>0.8.0-SNAPSHOT</version>
-                            <type>jar</type>
-                        </dependency>
-                    </dependencies>
                 </plugin>
                 <plugin>
                     <groupId>org.ops4j.pax.exam</groupId>
index 961ab7c0067e01afd2fb39dcc76ae4b8277fe87e..e737a3a84e079ca9e5b03e95f679ec08e4cb77de 100644 (file)
@@ -78,21 +78,6 @@ public class YangToSourcesPluginTestIT {
         fail("Verification exception should have been thrown");
     }
 
-    @Test
-    public void testNamingConflict() throws Exception {
-        Verifier v = setUp("test-parent/NamingConflict/", false);
-        v.verifyErrorFreeLog();
-        String baseDir = v.getBasedir();
-        String fileName = v.getLogFileName();
-        List<String> lines = v.loadFile(baseDir, fileName, false);
-        for (String s : lines) {
-            if (s.contains("conflict")) {
-                System.err.println(s);
-            }
-        }
-        v.verifyTextInLog("[WARNING] Naming conflict for type 'org.opendaylight.yang.gen.v1.urn.yang.test.rev140303.NetworkTopologyRef': file with same name already exists and will not be generated.");
-    }
-
     static void verifyCorrectLog(final Verifier v) throws VerificationException {
         v.verifyErrorFreeLog();
         v.verifyTextInLog("[INFO] yang-to-sources: YANG files parsed from");
diff --git a/yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/pom.xml b/yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/pom.xml
deleted file mode 100644 (file)
index 3cd6c5a..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- vi: set et smarttab sw=4 tabstop=4: -->
-<!-- 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 -->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-    <modelVersion>4.0.0</modelVersion>
-
-    <parent>
-        <groupId>org.opendaylight.yangtools</groupId>
-        <artifactId>test-parent</artifactId>
-        <version>@project.parent.version@</version>
-    </parent>
-
-    <artifactId>naming-conflict</artifactId>
-
-    <build>
-        <plugins>
-            <plugin>
-                <groupId>org.opendaylight.yangtools</groupId>
-                <artifactId>yang-maven-plugin</artifactId>
-                <version>${project.version}</version>
-                <executions>
-                    <execution>
-                        <goals>
-                            <goal>generate-sources</goal>
-                        </goals>
-                        <configuration>
-                            <inspectDependencies>false</inspectDependencies>
-                            <codeGenerators>
-                                <generator>
-                                    <codeGeneratorClass>
-                                        org.opendaylight.yangtools.maven.sal.api.gen.plugin.CodeGeneratorImpl
-                                    </codeGeneratorClass>
-                                    <outputBaseDir>
-                                        target/generated-sources
-                                    </outputBaseDir>
-                                </generator>
-                            </codeGenerators>
-                        </configuration>
-                    </execution>
-                </executions>
-                <dependencies>
-                    <dependency>
-                        <groupId>org.opendaylight.mdsal</groupId>
-                        <artifactId>maven-sal-api-gen-plugin</artifactId>
-                        <version>${project.version}</version>
-                        <type>jar</type>
-                    </dependency>
-                </dependencies>
-            </plugin>
-        </plugins>
-    </build>
-</project>
diff --git a/yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/src/main/yang/test.yang b/yang/yang-maven-plugin-it/src/test/resources/test-parent/NamingConflict/src/main/yang/test.yang
deleted file mode 100644 (file)
index e26c215..0000000
+++ /dev/null
@@ -1,18 +0,0 @@
-module test {
-    namespace "urn:yang:test";
-    prefix "t";
-
-    revision 2014-03-03 {
-    }
-
-    typedef network-topology-ref {
-        type instance-identifier;
-    }
-
-    grouping network-topology-ref {
-        leaf network-topology-ref {
-            type string;
-        }
-    }
-
-}
diff --git a/yang/yang-model-parent/pom.xml b/yang/yang-model-parent/pom.xml
deleted file mode 100644 (file)
index fd7aa1e..0000000
+++ /dev/null
@@ -1,128 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- vi: set et smarttab sw=4 tabstop=4: -->
-<!--
- Copyright (c) 2014 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
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-
-    <parent>
-        <groupId>org.opendaylight.odlparent</groupId>
-        <artifactId>bundle-parent</artifactId>
-        <version>1.6.0-SNAPSHOT</version>
-        <relativePath/>
-    </parent>
-
-    <modelVersion>4.0.0</modelVersion>
-    <groupId>org.opendaylight.yangtools</groupId>
-    <artifactId>yang-model-parent</artifactId>
-    <packaging>pom</packaging>
-    <version>0.8.0-SNAPSHOT</version>
-
-    <properties>
-        <yangtools.version>0.8.0-SNAPSHOT</yangtools.version>
-    </properties>
-
-    <dependencyManagement>
-        <dependencies>
-            <dependency>
-                <groupId>org.opendaylight.yangtools</groupId>
-                <artifactId>yangtools-artifacts</artifactId>
-                <version>${yangtools.version}</version>
-                <scope>import</scope>
-                <type>pom</type>
-            </dependency>
-        </dependencies>
-    </dependencyManagement>
-
-    <build>
-        <pluginManagement>
-            <plugins>
-                <plugin>
-                    <groupId>org.opendaylight.yangtools</groupId>
-                    <artifactId>yang-maven-plugin</artifactId>
-                    <version>${yangtools.version}</version>
-                    <executions>
-                        <execution>
-                            <goals>
-                                <goal>generate-sources</goal>
-                            </goals>
-                            <configuration>
-                                <yangFilesRootDir>src/main/yang</yangFilesRootDir>
-                                <codeGenerators>
-                                    <generator>
-                                        <codeGeneratorClass>
-                                            org.opendaylight.yangtools.maven.sal.api.gen.plugin.CodeGeneratorImpl
-                                        </codeGeneratorClass>
-                                        <outputBaseDir>
-                                            target/generated-sources/sal
-                                        </outputBaseDir>
-                                    </generator>
-                                    <generator>
-                                        <codeGeneratorClass>org.opendaylight.yangtools.yang.unified.doc.generator.maven.DocumentationGeneratorImpl</codeGeneratorClass>
-                                        <outputBaseDir>target/site/restconf</outputBaseDir>
-                                    </generator>
-                                    <generator>
-                                        <codeGeneratorClass>org.opendaylight.yangtools.yang.wadl.generator.maven.WadlGenerator</codeGeneratorClass>
-                                        <outputBaseDir>target/site/restconf</outputBaseDir>
-                                    </generator>
-                                </codeGenerators>
-                                <inspectDependencies>true</inspectDependencies>
-                            </configuration>
-                        </execution>
-                    </executions>
-                    <dependencies>
-                        <dependency>
-                            <groupId>org.opendaylight.mdsal</groupId>
-                            <artifactId>maven-sal-api-gen-plugin</artifactId>
-                            <version>${yangtools.version}</version>
-                            <type>jar</type>
-                        </dependency>
-                    </dependencies>
-                </plugin>
-
-                <!--This plugin's configuration is used to store Eclipse
-                    m2e settings only. It has no influence on the Maven build itself. -->
-                <plugin>
-                    <groupId>org.eclipse.m2e</groupId>
-                    <artifactId>lifecycle-mapping</artifactId>
-                    <version>1.0.0</version>
-                    <configuration>
-                        <lifecycleMappingMetadata>
-                            <pluginExecutions>
-                                <pluginExecution>
-                                    <pluginExecutionFilter>
-                                        <groupId>org.opendaylight.yangtools</groupId>
-                                        <artifactId>yang-maven-plugin</artifactId>
-                                        <versionRange>[0.5,)</versionRange>
-                                        <goals>
-                                            <goal>generate-sources</goal>
-                                        </goals>
-                                    </pluginExecutionFilter>
-                                    <action>
-                                        <ignore />
-                                    </action>
-                                </pluginExecution>
-                            </pluginExecutions>
-                        </lifecycleMappingMetadata>
-                    </configuration>
-                </plugin>
-            </plugins>
-        </pluginManagement>
-    </build>
-
-    <dependencies>
-        <dependency> 
-            <groupId>org.opendaylight.mdsal</groupId> 
-            <artifactId>yang-binding</artifactId> 
-        </dependency> 
-        <dependency> 
-            <groupId>org.opendaylight.yangtools</groupId> 
-            <artifactId>yang-common</artifactId> 
-        </dependency> 
-    </dependencies>
-</project>