Skip to content

Commit

Permalink
Failing test for #4615
Browse files Browse the repository at this point in the history
  • Loading branch information
mccartney committed Nov 3, 2024
1 parent b09b22f commit a69ce3c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions rewrite-gradle/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ dependencies {
// because gradle-api fatjars this implementation already
exclude("ch.qos.logback", "logback-classic")
}
testImplementation("org.junit-pioneer:junit-pioneer:2.0.0")

testImplementation("org.openrewrite.gradle.tooling:model:$latest")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@
*/
package org.openrewrite.gradle;

import org.junitpioneer.jupiter.ExpectedToFail;
import org.junit.jupiter.api.Test;
import org.openrewrite.Issue;
import org.openrewrite.java.tree.J;
import org.openrewrite.test.RewriteTest;

Expand Down Expand Up @@ -188,4 +190,17 @@ void handleImportsThatArentTheFirstStatement() {
)
);
}

@Issue("https://github.com/openrewrite/rewrite/issues/4615")
@ExpectedToFail
@Test
void parensAroundAnExpression() {
rewriteRun(
buildGradle(
"""
def version = (rootProject.jobName.startsWith('a')) ? "latest.release" : "3.0"
"""
)
);
}
}

0 comments on commit a69ce3c

Please sign in to comment.