[
https://issues.jboss.org/browse/ARQ-1586?page=com.atlassian.jira.plugin.s...
]
Juraj Húska commented on ARQ-1586:
----------------------------------
IMHO the _ClassContext_ should be available.
This is the arquillian.debug output when running with testNG: (see the
TestContextHandler.createClassContext)
{noformat:title=TESTNG debug}
(E) Before
(I) TestContextHandler.createSuiteContext
(I) TestContextHandler.createClassContext
(E) TestClass
(I) TestContextHandler.createTestContext
(I) ContainerEventController.createBeforeContext
(O) TestInstanceEnricher.enrich
(E) BeforeEnrichment
(O) ContextRootStoreInitializer.setupLocationForClass
(E) ContextRootStore
(E) DroneLifecycleEvent
(O) DroneInstanceCreator.createDroneInstance
(E) DroneLifecycleEvent
(O) WindowResizer.resizeBrowserWindow
(O) DroneEnhancer.enhanceDrone
(E) DroneEnhancementEvent
(E) DroneEnhancementEvent
(O) WindowResizer.resizeBrowserWindow
(E) AfterEnrichment
(O) DroneConfigurator.configureDrone
(O) ClientBeforeAfterLifecycleEventExecuter.on
{noformat}
These are the active contexts in {{Before}}:
{{[org.jboss.arquillian.core.impl.context.ApplicationContextImpl@d4ec36]}}
This is the output when running with junit:
{noformat:title=JUNIT debug}
(E) Before
(I) TestContextHandler.createSuiteContext
(I) TestContextHandler.createClassContext
(E) TestClass
(I) TestContextHandler.createTestContext
(I) ContainerEventController.createBeforeContext
(O) DroneConfigurator.configureDrone
(O) TestInstanceEnricher.enrich
(E) BeforeEnrichment
(O) ContextRootStoreInitializer.setupLocationForClass
(E) ContextRootStore
(E) DroneLifecycleEvent
(O) DroneInstanceCreator.createDroneInstance
(E) DroneLifecycleEvent
(O) DroneEnhancer.enhanceDrone
(E) DroneEnhancementEvent
(E) DroneEnhancementEvent
(O) WindowResizer.resizeBrowserWindow
(O) WindowResizer.resizeBrowserWindow
(E) AfterEnrichment
(O) ClientBeforeAfterLifecycleEventExecuter.on
{noformat}
These are the active contexts:
{{[org.jboss.arquillian.core.impl.context.ApplicationContextImpl@62b3beda,
org.jboss.arquillian.test.impl.context.ClassContextImpl@6b70cd6,
org.jboss.arquillian.container.impl.context.ContainerContextImpl@5babb90b,
org.jboss.arquillian.container.impl.context.DeploymentContextImpl@6701b031,
org.jboss.arquillian.test.impl.context.TestContextImpl@1fd695cc,
org.jboss.arquillian.test.impl.context.SuiteContextImpl@41049468]}}
Other ideas:
* ClassContextImpl is available _(E) After_
* The JUnit part contains _(O) DroneConfigurator.configureDrone_, the testng not.
ClassContextImpl is not active during TestNG @BeforeMethod
----------------------------------------------------------
Key: ARQ-1586
URL:
https://issues.jboss.org/browse/ARQ-1586
Project: Arquillian
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Base Implementation
Affects Versions: 1.1.1.Final
Reporter: Juraj Húska
When I call
[
this|https://github.com/arquillian/arquillian-graphene/blob/master/api/sr...]
Arquillian Graphene's method in method annotated with TestNG {{@BeforeMethod}}, then
it is not possible to get Graphene's configuration.
On this
[
line|https://github.com/arquillian/arquillian-graphene/blob/master/impl/s...],
{{configuration.get()}} returns {{null}}.
The configuration should be retrieved from {{Instance<GrapheneConfiguration>}}.
However, it is not.
When I compare this to JUnit {{@Before}}, I came to this:
At {{ManagerImpl.java}}
[
here|https://github.com/arquillian/arquillian-core/blob/master/core/impl-...],
the configuration is retrieved from context {{ClassContextImpl}}.
However, that context is not marked as active when executing from TestNG (among the
others contexts).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira