[JBoss JIRA] (ARQGRA-415) Cloudbees matrix job fails with NPE
by Lukáš Fryč (JIRA)
[ https://issues.jboss.org/browse/ARQGRA-415?page=com.atlassian.jira.plugin... ]
Lukáš Fryč resolved ARQGRA-415.
-------------------------------
Assignee: Lukáš Fryč
Resolution: Won't Fix
> Cloudbees matrix job fails with NPE
> -----------------------------------
>
> Key: ARQGRA-415
> URL: https://issues.jboss.org/browse/ARQGRA-415
> Project: Arquillian Graphene
> Issue Type: Task
> Reporter: Lukáš Fryč
> Assignee: Lukáš Fryč
>
> https://arquillian.ci.cloudbees.com/job/arquillian-graphene-webdriver-fte...
> {code}
> Error Message
> Could not invoke deployment method: public static org.jboss.shrinkwrap.api.spec.WebArchive org.jboss.arquillian.graphene.ftest.condition.ConditionsTestCase.createTestArchive()
> Stacktrace
> java.lang.RuntimeException: Could not invoke deployment method: public static org.jboss.shrinkwrap.api.spec.WebArchive org.jboss.arquillian.graphene.ftest.condition.ConditionsTestCase.createTestArchive()
> at org.jboss.arquillian.container.test.impl.client.deployment.AnnotationDeploymentScenarioGenerator.invoke(AnnotationDeploymentScenarioGenerator.java:177)
> at org.jboss.arquillian.container.test.impl.client.deployment.AnnotationDeploymentScenarioGenerator.generateDeployment(AnnotationDeploymentScenarioGenerator.java:99)
> at org.jboss.arquillian.container.test.impl.client.deployment.AnnotationDeploymentScenarioGenerator.generate(AnnotationDeploymentScenarioGenerator.java:62)
> at org.jboss.arquillian.container.test.impl.client.deployment.DeploymentGenerator.generateDeployment(DeploymentGenerator.java:79)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:94)
> at org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)
> at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)
> at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:135)
> at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:115)
> at org.jboss.arquillian.core.impl.EventImpl.fire(EventImpl.java:67)
> at org.jboss.arquillian.container.test.impl.client.ContainerEventController.execute(ContainerEventController.java:100)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:94)
> at org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:99)
> at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:81)
> at org.jboss.arquillian.test.impl.TestContextHandler.createClassContext(TestContextHandler.java:75)
> at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:94)
> at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:88)
> at org.jboss.arquillian.test.impl.TestContextHandler.createSuiteContext(TestContextHandler.java:60)
> at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:94)
> at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:88)
> at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:135)
> at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:115)
> at org.jboss.arquillian.test.impl.EventTestRunnerAdaptor.beforeClass(EventTestRunnerAdaptor.java:80)
> at org.jboss.arquillian.junit.Arquillian$2.evaluate(Arquillian.java:182)
> at org.jboss.arquillian.junit.Arquillian.multiExecute(Arquillian.java:314)
> at org.jboss.arquillian.junit.Arquillian.access$100(Arquillian.java:46)
> at org.jboss.arquillian.junit.Arquillian$3.evaluate(Arquillian.java:199)
> at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
> at org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:147)
> at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:53)
> at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:123)
> at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:104)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.apache.maven.surefire.util.ReflectionUtils.invokeMethodWithArray(ReflectionUtils.java:164)
> at org.apache.maven.surefire.booter.ProviderFactory$ProviderProxy.invoke(ProviderFactory.java:110)
> at org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:172)
> at org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcessWhenForked(SurefireStarter.java:104)
> at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:70)
> Caused by: java.lang.reflect.InvocationTargetException
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:606)
> at org.jboss.arquillian.container.test.impl.client.deployment.AnnotationDeploymentScenarioGenerator.invoke(AnnotationDeploymentScenarioGenerator.java:173)
> ... 54 more
> Caused by: java.lang.NullPointerException
> at org.jboss.arquillian.graphene.ftest.Resource$ResourceBuilder.all(Resource.java:81)
> at org.jboss.arquillian.graphene.ftest.Resources.all(Resources.java:65)
> at org.jboss.arquillian.graphene.ftest.condition.ConditionsTestCase.createTestArchive(ConditionsTestCase.java:79)
> ... 59 more
> {code}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
10 years, 3 months
[JBoss JIRA] (ARQGRA-461) Running Graphene tests and use parallelStream method makes test fail with java.lang.IllegalStateException: The Graphene runtime isn't initialized. Exception.
by Lukáš Fryč (JIRA)
[ https://issues.jboss.org/browse/ARQGRA-461?page=com.atlassian.jira.plugin... ]
Lukáš Fryč resolved ARQGRA-461.
-------------------------------
Assignee: Lukáš Fryč
Resolution: Rejected
Agree, {{parallelStream()}} is in Selenium / Graphene 2.x a misuse that is expected to lead into threading issues.
If there would be really an elevated need, we may re-consider allowing such a usage by propagating contexts.
Thanks for describing the issue though, Alex, at least for future reference, as you say!
> Running Graphene tests and use parallelStream method makes test fail with java.lang.IllegalStateException: The Graphene runtime isn't initialized. Exception.
> -------------------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: ARQGRA-461
> URL: https://issues.jboss.org/browse/ARQGRA-461
> Project: Arquillian Graphene
> Issue Type: Bug
> Reporter: Alex Soto
> Assignee: Lukáš Fryč
> Priority: Minor
> Labels: java8,, threads
>
> Running Graphene tests and use parallelStream method makes test fail with java.lang.IllegalStateException: The Graphene runtime isn't initialized. Exception.
> Basically the problem is when you want to get information about tables. You can iterate over elements in a foreach fashion, but you can also use new Java 8 stream API.
> This works: ession.findElements(xpath("//table/tbody/tr/td/span[@class='title']")).stream().map(WebElement::getText).collect(Collectors.toList());
> But if table is big you will try to improve parsing speed by adding parallelSteam (session.findElements(xpath("//table/tbody/tr/td/span[@class='title']")).parallelStream().map(WebElement::getText).collect(Collectors.toList());)
> And in this case an exception is thrown.
> Internally parallelStream uses a pool of threads so probably Graphene instance is tight to thread of test case, so the threads used by parallelStream does not contains a valid instance of Graphene.
> Of course this is not blocking nor a big problem in the sense that you can use stream() without any problem, and moreover Java 8 is not spread yet, but it may be a problem in the future.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
10 years, 3 months
[JBoss JIRA] (ARQGRA-411) GrapheneElement methods should wait until element is present
by Lukáš Fryč (JIRA)
[ https://issues.jboss.org/browse/ARQGRA-411?page=com.atlassian.jira.plugin... ]
Lukáš Fryč resolved ARQGRA-411.
-------------------------------
Assignee: Lukáš Fryč
Resolution: Incomplete Description
> GrapheneElement methods should wait until element is present
> ------------------------------------------------------------
>
> Key: ARQGRA-411
> URL: https://issues.jboss.org/browse/ARQGRA-411
> Project: Arquillian Graphene
> Issue Type: Feature Request
> Reporter: Emil Cervenan
> Assignee: Lukáš Fryč
>
> Scenarios when element is generated by javascript and performance is low leads to situations when method of element which is not present is called. Unwanted exception is thrown. When you are trying to simulate users behaviour it is clear you are not expecting clicking, typing and so on to elements which are not present. Therefore each GrapheneElement method should wait until element is present.
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)
10 years, 3 months