Repository: groovy
Updated Branches:
  refs/heads/GROOVY_2_5_X 07f22b69f -> b1f6ccc9e


Remove lambda code in test code

(cherry picked from commit ea4c330)


Project: http://git-wip-us.apache.org/repos/asf/groovy/repo
Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/b1f6ccc9
Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/b1f6ccc9
Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/b1f6ccc9

Branch: refs/heads/GROOVY_2_5_X
Commit: b1f6ccc9e0a51a467f6c1de916b7be1095a0c3e6
Parents: 07f22b6
Author: danielsun1106 <[email protected]>
Authored: Sun Mar 4 13:01:43 2018 +0800
Committer: danielsun1106 <[email protected]>
Committed: Sun Mar 4 13:04:28 2018 +0800

----------------------------------------------------------------------
 .../memoize/ConcurrentCommonCacheTest.java      | 21 +++++++++++---------
 1 file changed, 12 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/groovy/blob/b1f6ccc9/src/test/org/codehaus/groovy/runtime/memoize/ConcurrentCommonCacheTest.java
----------------------------------------------------------------------
diff --git 
a/src/test/org/codehaus/groovy/runtime/memoize/ConcurrentCommonCacheTest.java 
b/src/test/org/codehaus/groovy/runtime/memoize/ConcurrentCommonCacheTest.java
index a8d57f5..687e5b1 100644
--- 
a/src/test/org/codehaus/groovy/runtime/memoize/ConcurrentCommonCacheTest.java
+++ 
b/src/test/org/codehaus/groovy/runtime/memoize/ConcurrentCommonCacheTest.java
@@ -214,15 +214,18 @@ public class ConcurrentCommonCacheTest {
         final AtomicInteger cnt = new AtomicInteger(0);
 
         for (int i = 0; i < threadNum; i++) {
-            new Thread(() -> {
-                try {
-                    countDownLatch.await();
-
-                    m.getAndPut(123, k -> cnt.getAndIncrement());
-                } catch (InterruptedException e) {
-                    e.printStackTrace();
-                } finally {
-                    countDownLatch2.countDown();
+            new Thread(new Runnable() {
+                @Override
+                public void run() {
+                    try {
+                        countDownLatch.await();
+
+                        m.getAndPut(123, k -> cnt.getAndIncrement());
+                    } catch (InterruptedException e) {
+                        e.printStackTrace();
+                    } finally {
+                        countDownLatch2.countDown();
+                    }
                 }
             }).start();
         }

Reply via email to