Uploaded image for project: 'Arquillian'
  1. Arquillian
  2. ARQ-1819

CDI not working in Jboss as 7.1

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • None
    • None
    • None
    • None

      Hi Guys, I am having problems in Arquillian CDI.
      I am using in my parent pom....
      <dependency>
      <groupId>org.jboss.arquillian.junit</groupId>
      <artifactId>arquillian-junit-container</artifactId>
      <version>1.0.0.CR7</version>
      <scope>test</scope>
      </dependency>

      My Arquillian.xml is like this

      <?xml version="1.0" encoding="UTF-8"?>
      <arquillian xmlns="http://jboss.org/schema/arquillian"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://jboss.org/schema/arquillian
      http://jboss.org/schema/arquillian/arquillian_1_0.xsd">

      <engine>
      <property name="deploymentExportPath">/SDDevelopmentMVN/TEST_temp</property>
      </engine>

      <!-- Example configuration for a remote JBoss AS 7 instance -->
      <container qualifier="jboss" default="true">
      <protocol type="jmx-as7">
      <property name="executionType">REMOTE</property>
      </protocol>
      <configuration>
      <property name="jbossHome">/SDDevelopmentMVN/jboss/jbossInternalMVN</property>
      <property name="managementAddress">127.0.0.1</property>
      <property name="managementPort">10099</property>
      </configuration>
      </container>

      </arquillian>
      -------------------------

      My Test class is
      @RunWith(Arquillian.class)
      @RunAsClient
      public class PayrollCRUDServiceRestfullTest {

      @Deployment
      public static Archive<?> createTestArchive()

      { return ShrinkWrap.create(WebArchive.class, "test1177.war") .addClasses(MiscUtilsSD.class,GenericAuditService.class,PayrollCRUDService.class, SmartDAO.class,Resources.class) .addPackage("com.animation2000.coreservices.domain") .addPackage("com.animation2000.coreservices.audit.domain") .addPackage("com.animation2000.coreservices.audit.service") .addPackage("com.animation2000.coreservices.audit.wrapper") .addPackage("com.animation2000.coreservices.domain.customized") .addPackage("com.animation2000.smart.dao") .addPackage("com.animation2000.coreservices.payroll.crud.service") .addAsResource("META-INF/persistence.xml", "META-INF/persistence.xml") .addAsWebInfResource(EmptyAsset.INSTANCE, ArchivePaths.create("beans.xml")); }

      @Inject
      PayrollCRUDService payrollCRUDService;

      But payrollCRUDService is null..

      Any advise?Please.

      Many Thanks

            Unassigned Unassigned
            sumncc_jira Raj Haque (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: