Permalink
Browse files

GRAILS-8273 - Fix "enum.values() as Set"

This problem was fixed when in Groovy 1.8.5 when GROOVY-5210 was resolved.
  • Loading branch information...
1 parent ef01664 commit c6db4f73a213becabf6b6de404d9b086704198f3 @jeffbrown jeffbrown committed Mar 22, 2012
@@ -0,0 +1,17 @@
+package org.codehaus.groovy.grails.plugins.converters.api
+
+import spock.lang.Specification
+
+class ConvertersApiSpec extends Specification {
+ void 'Test converting an array to an interface type'() {
+ given:
+ def converter = new ConvertersApi()
+
+ when:
+ def someArray = ['One', 'Two', 'One', 'Three'] as String[]
+ def someSet = converter.asType(someArray, Set)
+
+ then:
+ someSet instanceof Set
+ }
+}

0 comments on commit c6db4f7

Please sign in to comment.