diff options
author | Bruno Sakoto <bruno.sakoto@bell.ca> | 2021-07-14 11:15:48 -0400 |
---|---|---|
committer | Bruno Sakoto <bruno.sakoto@bell.ca> | 2021-07-14 11:24:14 -0400 |
commit | ff5f74dcdc0d889aabed8351223a71ddd55f8ccc (patch) | |
tree | 91e0f0ea01a3532001fe13c8c9778710dfa8b65f | |
parent | b208aeb1904a95ebd08466908ae6e222d5a7a75a (diff) |
Review checkstyle configuration
Existing violation is also fixed.
Issue-ID: CPS-504
Signed-off-by: Bruno Sakoto <bruno.sakoto@bell.ca>
Change-Id: Ib7ebb62d0181f92803b5faa64d9a638b17fcbdb8
-rw-r--r-- | pom.xml | 38 | ||||
-rw-r--r-- | src/main/java/org/onap/cps/ncmp/rest/controller/DmiRestController.java | 2 |
2 files changed, 39 insertions, 1 deletions
@@ -203,6 +203,44 @@ <artifactId>maven-checkstyle-plugin</artifactId> <executions> <execution> + <id>onap-license</id> + <goals> + <goal>check</goal> + </goals> + <phase>process-sources</phase> + <configuration> + <configLocation>onap-checkstyle/check-license.xml</configLocation> + <includeResources>false</includeResources> + <includeTestSourceDirectory>true</includeTestSourceDirectory> + <includeTestResources>false</includeTestResources> + <sourceDirectories> + <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory> + </sourceDirectories> + <consoleOutput>false</consoleOutput> + <violationSeverity>warning</violationSeverity> + <failOnViolation>true</failOnViolation> + </configuration> + </execution> + <execution> + <id>onap-java-style</id> + <goals> + <goal>check</goal> + </goals> + <phase>process-sources</phase> + <configuration> + <configLocation>onap-checkstyle/onap-java-style.xml</configLocation> + <sourceDirectories> + <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory> + </sourceDirectories> + <includeResources>true</includeResources> + <includeTestSourceDirectory>true</includeTestSourceDirectory> + <includeTestResources>true</includeTestResources> + <consoleOutput>false</consoleOutput> + <violationSeverity>warning</violationSeverity> + <failOnViolation>true</failOnViolation> + </configuration> + </execution> + <execution> <id>cps-java-style</id> <goals> <goal>check</goal> diff --git a/src/main/java/org/onap/cps/ncmp/rest/controller/DmiRestController.java b/src/main/java/org/onap/cps/ncmp/rest/controller/DmiRestController.java index 57542102..16fb73a8 100644 --- a/src/main/java/org/onap/cps/ncmp/rest/controller/DmiRestController.java +++ b/src/main/java/org/onap/cps/ncmp/rest/controller/DmiRestController.java @@ -37,7 +37,7 @@ public class DmiRestController implements DmiPluginApi { @Override public ResponseEntity<Object> helloWorld() { - final var helloWorld = dmiService.getHelloWorld() ; + final var helloWorld = dmiService.getHelloWorld(); return new ResponseEntity<>(helloWorld, HttpStatus.OK); } |