[jboss-as7-dev] Running AS7 tests in eclipse?

Jeff Mesnil jmesnil at redhat.com
Tue Apr 3 09:01:19 EDT 2012


Hi,

It's a silly question but I ask it anyway: how do you run individual AS7 
tests in eclipse?

I can not manage to run either messaging subsystem or integration tests 
individually from eclipse...

I followed docs[1][2] (incl. setting up the Maven profile) without any 
success. Any Arquillian test fails with the error:

org.jboss.arquillian.container.spi.ConfigurationException: jbossHome 
'null' must exist

and setting the jboss.home env variable in the run configuration does 
not work. Am I missing something obvious?
It seems weird that the file 
testsuite/integration/smoke/src/test/config/arq/arquillian.xml is not in 
eclipse's Build Path. But adding it does not have any effect

I made a simple project to familiarize myself with Arquillian and it 
works fine, I can deploy a JMS queue, test it, everything's fine.
But I'm at loss to run Arquillian individual tests from AS7...

The messaging susbystem tests fails too when in run them in eclipse with 
the error:

java.lang.Exception: java.lang.ExceptionInInitializerError
	at 
org.jboss.as.subsystem.test.AbstractSubsystemTest$ModelControllerService.boot(AbstractSubsystemTest.java:763)
	at 
org.jboss.as.controller.AbstractControllerService.boot(AbstractControllerService.java:185)
	at 
org.jboss.as.controller.AbstractControllerService$1.run(AbstractControllerService.java:155)
	at java.lang.Thread.run(Thread.java:679)
Caused by: java.lang.ExceptionInInitializerError
	at 
org.jboss.as.controller.AbstractOperationContext.doCompleteStep(AbstractOperationContext.java:322)
	at 
org.jboss.as.controller.AbstractOperationContext.completeStep(AbstractOperationContext.java:200)
	at 
org.jboss.as.controller.ModelControllerImpl.boot(ModelControllerImpl.java:149)
	at 
org.jboss.as.controller.AbstractControllerService.boot(AbstractControllerService.java:190)
	at 
org.jboss.as.subsystem.test.AbstractSubsystemTest$ModelControllerService.boot(AbstractSubsystemTest.java:759)
	... 3 more
Caused by: java.lang.IllegalArgumentException: Invalid logger interface 
org.jboss.as.controller.ControllerLogger (implementation not found)
	at org.jboss.logging.Logger.getMessageLogger(Logger.java:2250)
	at org.jboss.logging.Logger.getMessageLogger(Logger.java:2214)
	at 
org.jboss.as.controller.ControllerLogger.<clinit>(ControllerLogger.java:51)
	... 8 more

I have imported both jboss-as-messaging and jboss-as-controller projects 
in eclipse.
Is there something specific to do to have logging working in eclipse?

I feel dumb not being able to run a single test from eclipse... :)

thanks,
jeff

[1] https://community.jboss.org/wiki/HackingAS7UsingEclipse
[1] https://community.jboss.org/wiki/WritingAAS7TestCaseInTestsuiteModule

-- 
Jeff Mesnil
JBoss, a division of Red Hat
http://jmesnil.net/


More information about the jboss-as7-dev mailing list