0

When I try to run my appium scripts on the pom file ( with mvn verify or mvn test)

I get a

java.lang.RuntimeException: java.lang.NoSuchMethodException: jdk.proxy2.$Proxy12.proxyClassLookup()

On the line that instantiates my locators:

PageFactory.initElements(new AppiumFieldDecorator(driver, Duration.ofSeconds(15)), this);

When I run the test directly from InteliJ or run the testng.xml file, the test succeeds

What can be the problem, when everything is fine running from test class / testng.xml, but suddenly failing when running with maven in command line

1

it's a bit embarrassing, (because i remembered I did this before) After doing an mvn clean, and an mvn compile again,

Then the issue disappeared. something probably got stuck somewhere and needed a clean again..

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.