matrei commented on code in PR #15565:
URL: https://github.com/apache/grails-core/pull/15565#discussion_r3056607441


##########
grails-test-suite-web/src/test/groovy/org/grails/web/converters/JSONConverterTests.groovy:
##########
@@ -95,21 +95,14 @@ class JSONConverterTests extends Specification implements 
ControllerUnitTest<JSO
         def enumInstance = Role.HEAD
         params.e = enumInstance
         controller.testEnum()
-        def json = response.json
 
         then:
-        json.enumType == "org.grails.web.converters.Role"
-        json.name == "HEAD"
-        json.size() == 2
+        def e = thrown(ConverterException)

Review Comment:
   Previously you could render a single `Enum` as JSON. This is no longer 
possible. I saved that test as a sorts of documentation of this change in 
behavior. I will also add a comment to clarify that further and a section in 
the upgrade guide.



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