Since version 2.2.0.Beta2 the *bean archive isolation* (along with bean-discovery-mode from CDI 1.1) is supported in Weld SE. The isolation is enabled by default, i.e. you have two bean archives for each test and that's the reason for those unsatisfied dependencies.
Either [ select alternatives for an application |http://docs.jboss.org/cdi/spec/1.2/cdi-spec.html#declaring_selected_alternatives_application] or set the system property {{org.jboss.weld.se.archive.isolation}} to false in order to simulate the flat deployment (see also the [18.4.6. Bean archive isolation|http://docs.jboss.org/weld/reference/latest/en-US/html/environments.html] section in the docs).
I've tried to set the system property in the {{build.gradle}} file and the deployment exception has gone. However, another one emerged: {{java.lang.NoClassDefFoundError: Could not initialize class groovy.lang.GroovySystem}}... I'm not sure about the cause.
|