Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Appium pages have null web driver in some step libraries #1828

Closed
justinhinze opened this issue Oct 1, 2019 · 1 comment
Closed

Appium pages have null web driver in some step libraries #1828

justinhinze opened this issue Oct 1, 2019 · 1 comment

Comments

@justinhinze
Copy link

The web driver and elements are null in page objects in some step libraries but not others.

  • Only when tests are run with CucumberWithSerenity.class
  • Only when using Appium driver
  • Same with serenity-cucumber and serenity-cucumber4

Stack Trace
java.lang.NullPointerException at suite.pages.SomePage.tapLocationStatus(SomePage.java:16) at suite.steps.SomeSteps.tapLocationStatus(SomeSteps.java:13) at suite.steps.SomeSteps$$EnhancerByCGLIB$$dbfafe36.CGLIB$tapLocationStatus$0(<generated>) at suite.steps.SomeSteps$$EnhancerByCGLIB$$dbfafe36$$FastClassByCGLIB$$4d4dfb2b.invoke(<generated>) at net.sf.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228) at net.thucydides.core.steps.StepInterceptor.invokeMethod(StepInterceptor.java:460) at net.thucydides.core.steps.StepInterceptor.executeTestStepMethod(StepInterceptor.java:445) at net.thucydides.core.steps.StepInterceptor.runTestStep(StepInterceptor.java:420) at net.thucydides.core.steps.StepInterceptor.runOrSkipMethod(StepInterceptor.java:175) at net.thucydides.core.steps.StepInterceptor.testStepResult(StepInterceptor.java:162) at net.thucydides.core.steps.StepInterceptor.intercept(StepInterceptor.java:68) at suite.steps.SomeSteps$$EnhancerByCGLIB$$dbfafe36.tapLocationStatus(<generated>) at step_definitions.MyStepdefs.doItAgain(MyStepdefs.java:23) at ✽.I should be able to do the same in another(src/test/resources/features/AFeature.feature:6)

App under test
https://github.com/appium/ios-test-app

Sample project
serenitycucumberfourappiumseven.zip

@wakaleo
Copy link
Member

wakaleo commented Oct 3, 2019

Maybe one of the Appium users can check this out?

@wakaleo wakaleo closed this as completed Feb 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants