Fix checkstyle build and xml 70/78070/1
authorPamela Dragosh <pdragosh@research.att.com>
Thu, 7 Feb 2019 16:26:06 +0000 (11:26 -0500)
committerPamela Dragosh <pdragosh@research.att.com>
Thu, 7 Feb 2019 16:28:19 +0000 (11:28 -0500)
The XML for onap-java-code style has a bug identified by Eclipse. The
maxLineLength field is not allowed.

In addition, not sure how any jobs work already, the sourceDirectory
appends and extra "src/main/java" to the path so some builds don't
always find the correct source files to generate warnings. The plugin
is a bit flaky and sometimes seems to find the java files, while other
times it does not. So some checkstyle warnings are not generated.

Change-Id: Ia07065a0d0df1429643680cb5bd70b5ec13bebde
Issue-ID: TSC-71
Signed-off-by: Pamela Dragosh <pdragosh@research.att.com>
checkstyle/src/main/resources/onap-checkstyle/onap-java-style.xml
oparent/pom.xml

index 32439e2..77ef3ae 100644 (file)
@@ -73,7 +73,6 @@
         </module>
         <module name="NeedBraces"/>
         <module name="LeftCurly">
-            <property name="maxLineLength" value="120"/>
         </module>
         <module name="RightCurly">
             <property name="option" value="alone"/>
index 9441404..e678fc1 100644 (file)
                    with minor changes -->
               <configLocation>onap-checkstyle/onap-java-style.xml</configLocation>
               <!-- <sourceDirectory> is needed so that checkstyle ignores the generated sources directory -->
-              <sourceDirectory>${project.build.sourceDirectory}/src/main/java</sourceDirectory>
+              <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
               <includeResources>true</includeResources>
               <includeTestSourceDirectory>true</includeTestSourceDirectory>
               <includeTestResources>true</includeTestResources>