Bumped CheckStyle to version 10.18.0
This commit is contained in:
parent
143bb31a78
commit
becd6384cd
6 changed files with 24 additions and 18 deletions
6
.idea/bld.xml
generated
Normal file
6
.idea/bld.xml
generated
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="BldConfiguration">
|
||||||
|
<events />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -37,5 +37,5 @@ not provided by the extension. For example:
|
||||||
|
|
||||||
```java
|
```java
|
||||||
repositories = List.of(MAVEN_CENTRAL);
|
repositories = List.of(MAVEN_CENTRAL);
|
||||||
scope(test).include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 17, 0)));
|
scope(test).include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 18, 0)));
|
||||||
```
|
```
|
||||||
|
|
|
@ -23,7 +23,7 @@ public class ExamplesBuild extends BaseProject {
|
||||||
|
|
||||||
repositories = List.of(MAVEN_CENTRAL);
|
repositories = List.of(MAVEN_CENTRAL);
|
||||||
|
|
||||||
scope(test).include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 17, 0)));
|
scope(test).include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 18, 0)));
|
||||||
|
|
||||||
testOperation().mainClass("com.example.ExamplesTest");
|
testOperation().mainClass("com.example.ExamplesTest");
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,9 +43,9 @@ public class CheckstyleOperationBuild extends Project {
|
||||||
scope(compile)
|
scope(compile)
|
||||||
.include(dependency("com.uwyn.rife2", "bld", version(2, 0, 1)));
|
.include(dependency("com.uwyn.rife2", "bld", version(2, 0, 1)));
|
||||||
scope(test)
|
scope(test)
|
||||||
.include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 17, 0)))
|
.include(dependency("com.puppycrawl.tools", "checkstyle", version(10, 18, 0)))
|
||||||
.include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 10, 3)))
|
.include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 11, 0)))
|
||||||
.include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 10, 3)))
|
.include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 11, 0)))
|
||||||
.include(dependency("org.assertj", "assertj-core", version(3, 26, 3)));
|
.include(dependency("org.assertj", "assertj-core", version(3, 26, 3)));
|
||||||
javadocOperation()
|
javadocOperation()
|
||||||
.javadocOptions()
|
.javadocOptions()
|
||||||
|
|
|
@ -284,13 +284,6 @@ public class CheckstyleOperation extends AbstractProcessOperation<CheckstyleOper
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Determines if a string is not blank.
|
|
||||||
*/
|
|
||||||
private boolean isNotBlank(String s) {
|
|
||||||
return s != null && !s.isBlank();
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This option is used to print the Parse Tree of the Javadoc comment. The file has to contain only Javadoc comment
|
* This option is used to print the Parse Tree of the Javadoc comment. The file has to contain only Javadoc comment
|
||||||
* content excluding '/**' and '*/' at the beginning and at the end respectively. It can only be used on a
|
* content excluding '/**' and '*/' at the beginning and at the end respectively. It can only be used on a
|
||||||
|
@ -492,4 +485,11 @@ public class CheckstyleOperation extends AbstractProcessOperation<CheckstyleOper
|
||||||
}
|
}
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Determines if a string is not blank.
|
||||||
|
*/
|
||||||
|
private boolean isNotBlank(String s) {
|
||||||
|
return s != null && !s.isBlank();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -156,12 +156,6 @@ class CheckstyleOperationTest {
|
||||||
assertThat(tmpFile).exists();
|
assertThat(tmpFile).exists();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
|
||||||
void executeNoProject() {
|
|
||||||
var op = new CheckstyleOperation();
|
|
||||||
assertThatCode(op::execute).isInstanceOf(ExitStatusException.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void executeConstructProcessCommandList() {
|
void executeConstructProcessCommandList() {
|
||||||
var op = new CheckstyleOperation().fromProject(new BaseProject())
|
var op = new CheckstyleOperation().fromProject(new BaseProject())
|
||||||
|
@ -191,6 +185,12 @@ class CheckstyleOperationTest {
|
||||||
assertThat(op.options().containsKey("-E")).as(REMOVE).isFalse();
|
assertThat(op.options().containsKey("-E")).as(REMOVE).isFalse();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
void executeNoProject() {
|
||||||
|
var op = new CheckstyleOperation();
|
||||||
|
assertThatCode(op::execute).isInstanceOf(ExitStatusException.class);
|
||||||
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void executeSunChecks() throws IOException {
|
void executeSunChecks() throws IOException {
|
||||||
var tmpFile = File.createTempFile("checkstyle-sun", ".txt");
|
var tmpFile = File.createTempFile("checkstyle-sun", ".txt");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue