chia7712 commented on code in PR #16965:
URL: https://github.com/apache/kafka/pull/16965#discussion_r1807233775
##########
build.gradle:
##########
@@ -119,8 +119,16 @@ ext {
addParametersForTests = { name, options ->
// -parameters generates arguments with parameter names in
TestInfo#getDisplayName.
// ref:
https://github.com/junit-team/junit5/blob/4c0dddad1b96d4a20e92a2cd583954643ac56ac0/junit-jupiter-params/src/main/java/org/junit/jupiter/params/ParameterizedTest.java#L161-L164
- if (name == "compileTestJava" || name == "compileTestScala")
+ if (name == "compileTestJava" || name == "compileTestScala") {
options.compilerArgs << "-parameters"
+ } else if (name == "compileScala") {
Review Comment:
Could you please config both scala and java? for example:
```
if (name == "compileTestJava" || name == "compileTestScala") {
options.compilerArgs << "-parameters"
} else if (name == "compileJava" || name == "compileScala") {
options.compilerArgs << "-Xlint:all"
if (!project.path.startsWith(":connect") &&
!project.path.startsWith(":storage"))
options.compilerArgs << "-Xlint:-rawtypes"
options.compilerArgs << "-encoding" << "UTF-8"
options.compilerArgs << "-Xlint:-rawtypes"
options.compilerArgs << "-Xlint:-serial"
options.compilerArgs << "-Xlint:-try"
options.compilerArgs << "-Werror"
options.compilerArgs += ["--release", String.valueOf(minJavaVersion)]
}
```
##########
build.gradle:
##########
@@ -119,8 +119,16 @@ ext {
addParametersForTests = { name, options ->
// -parameters generates arguments with parameter names in
TestInfo#getDisplayName.
// ref:
https://github.com/junit-team/junit5/blob/4c0dddad1b96d4a20e92a2cd583954643ac56ac0/junit-jupiter-params/src/main/java/org/junit/jupiter/params/ParameterizedTest.java#L161-L164
- if (name == "compileTestJava" || name == "compileTestScala")
Review Comment:
Additionally, `addParametersForTests` -> `configureJavaCompiler`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]