You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by em...@apache.org on 2022/03/01 22:10:07 UTC
[groovy] branch GROOVY_2_5_X updated: fic for JDK7
This is an automated email from the ASF dual-hosted git repository.
emilles pushed a commit to branch GROOVY_2_5_X
in repository https://gitbox.apache.org/repos/asf/groovy.git
The following commit(s) were added to refs/heads/GROOVY_2_5_X by this push:
new 65eb573 fic for JDK7
65eb573 is described below
commit 65eb57387760a699836ac6ff82cb1c16768550c0
Author: Eric Milles <er...@thomsonreuters.com>
AuthorDate: Tue Mar 1 16:09:54 2022 -0600
fic for JDK7
---
src/test/groovy/transform/stc/ClosuresSTCTest.groovy | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/test/groovy/transform/stc/ClosuresSTCTest.groovy b/src/test/groovy/transform/stc/ClosuresSTCTest.groovy
index ef61a3d..5c262a0 100644
--- a/src/test/groovy/transform/stc/ClosuresSTCTest.groovy
+++ b/src/test/groovy/transform/stc/ClosuresSTCTest.groovy
@@ -345,6 +345,8 @@ class ClosuresSTCTest extends StaticTypeCheckingTestCase {
// GROOVY-10052
void testClosureSharedVariable4() {
+ if (!groovy.test.GroovyAssert.isAtLeastJdk('1.8')) return
+
assertScript '''
String x
def f = { ->
@@ -357,6 +359,8 @@ class ClosuresSTCTest extends StaticTypeCheckingTestCase {
// GROOVY-10052
void testClosureSharedVariable5() {
+ if (!groovy.test.GroovyAssert.isAtLeastJdk('1.8')) return
+
assertScript '''
def x
def f = { ->
@@ -369,6 +373,8 @@ class ClosuresSTCTest extends StaticTypeCheckingTestCase {
// GROOVY-10052
void testNotClosureSharedVariable() {
+ if (!groovy.test.GroovyAssert.isAtLeastJdk('1.8')) return
+
assertScript '''
String x = Optional.of('x').orElseThrow{ new Exception() }
def f = { ->