You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by pa...@apache.org on 2022/08/26 06:27:51 UTC

[groovy] 05/06: minor test refactor

This is an automated email from the ASF dual-hosted git repository.

paulk pushed a commit to branch GROOVY_4_0_X
in repository https://gitbox.apache.org/repos/asf/groovy.git

commit 9922519447d0f9194c2d9f2e86d43a63672668f3
Author: Paul King <pa...@asert.com.au>
AuthorDate: Thu Aug 25 23:33:23 2022 +1000

    minor test refactor
---
 .../org/codehaus/groovy/transform/ImmutableTransformTest.groovy    | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/test/org/codehaus/groovy/transform/ImmutableTransformTest.groovy b/src/test/org/codehaus/groovy/transform/ImmutableTransformTest.groovy
index 85ad505dfc..f108715511 100644
--- a/src/test/org/codehaus/groovy/transform/ImmutableTransformTest.groovy
+++ b/src/test/org/codehaus/groovy/transform/ImmutableTransformTest.groovy
@@ -110,9 +110,10 @@ class ImmutableTransformTest extends GroovyShellTestCase {
 
     @Test
     void testCloneableField() {
-        def (originalDolly, lab) = evaluate("""
-            import groovy.transform.Immutable
+        def (originalDolly, lab) = evaluate('''
+            import groovy.transform.*
 
+            @AutoClone
             class Dolly implements Cloneable {
                 String name
             }
@@ -124,7 +125,7 @@ class ImmutableTransformTest extends GroovyShellTestCase {
 
             def dolly = new Dolly(name: "The Sheep")
             [dolly, new Lab(name: "Area 51", clone: dolly)]
-        """)
+        ''')
 
         def clonedDolly = lab.clone
         def clonedDolly2 = lab.clone