Copilot commented on code in PR #2573:
URL: https://github.com/apache/groovy/pull/2573#discussion_r3329524805


##########
subprojects/groovy-contracts/src/test/groovy/org/apache/groovy/contracts/tests/post/SimplePostconditionTests.groovy:
##########
@@ -166,8 +166,9 @@ class Account {
         }
     }
 
+    // GROOVY-12052
     @Test
-    void no_postcondition_on_static_methods() {
+    void postcondition_on_static_void_method() {

Review Comment:
   This test is named for the static `void` case, but the method under test is 
`def` and returns `amount`, so the newly enabled static postcondition path for 
primitive `void` methods is still untested. Making this source method actually 
`void` keeps the intended coverage and exercises the branch that appends 
postconditions without a `result` value.



-- 
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]

Reply via email to