Skip to content
This repository has been archived by the owner on Dec 4, 2023. It is now read-only.

Commit

Permalink
[Linter] Upgrade Checkstyle plugin to 3.1.2 supporting Checkstyle ver…
Browse files Browse the repository at this point in the history
…sion up to 8.41 (#1226)

* Upgrade checkstyle plugin to latest version 3.1.2

* Update rules to support Checkstyle 8.41

* Fix linter issue
  • Loading branch information
Batta32 authored Jun 9, 2021
1 parent 7740765 commit 104b7e8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
9 changes: 5 additions & 4 deletions etc/bot-checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,10 @@

<module name="SuppressWarningsFilter" />

<module name="LineLength">
<property name="max" value="120"/>
</module>

<module name="TreeWalker">
<!-- check for usage of literal equality "==" between string -->
<module name="StringLiteralEquality"/>
Expand Down Expand Up @@ -125,10 +129,7 @@
</module>

<!-- Checks for Size Violations. -->
<!-- See http://checkstyle.sourceforge.net/config_sizes.html -->
<module name="LineLength">
<property name="max" value="120"/>
</module>
<!-- See http://checkstyle.sourceforge.net/config_sizes.html -->
<module name="MethodLength"/>
<module name="ParameterNumber"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,12 +57,12 @@ public void setService(T withService) {
this.service = withService;
}

@Override
/**
* Adds the associated object or service to the current turn context.
* @param turnContext The context object for this turn.
* @param next The delegate to call to continue the bot middleware pipeline.
*/
@Override
public CompletableFuture<Void> onTurn(TurnContext turnContext, NextDelegate next) {
if (!StringUtils.isBlank(key)) {
turnContext.getTurnState().add(key, service);
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<jdk.version>1.8</jdk.version>
<maven.compiler.target>1.8</maven.compiler.target>
<maven.compiler.source>1.8</maven.compiler.source>
<checkstyle.version>3.1.0</checkstyle.version>
<checkstyle.version>3.1.2</checkstyle.version>
<pmd.version>3.14.0</pmd.version>
<exclude.tests>%regex[.*recognizers.*]</exclude.tests>
<!-- <repo.id>MyGet</repo.id> -->
Expand Down

0 comments on commit 104b7e8

Please sign in to comment.