appium / java-client

Java language binding for writing Appium Tests, conforms to W3C WebDriver Protocol
Apache License 2.0
1.22k stars 758 forks source link

NoSign flag + uiautomator #275

Closed stonesong closed 8 years ago

stonesong commented 8 years ago

Hi, I am using java-client with @AndroidFindBy(uiAutomator = etc.) And it works great, but still appium desired capabilities capabilities.setCapability("noSign", true); is no effective. My map won't appear due to resigning of the apk from appium. I run this on android 4.3. Still the appium doc says "will work only with UiAutomator and not with selendroid". Am I missing anything ? I can't find code samples about this. Pierre

TikhomirovSergey commented 8 years ago

@stonesong Hi I have some questions How is @AndroidFindBy(uiAutomator = etc.) connected with capabilities.setCapability("noSign", true)? Do you get the desired result using

MobileElement e = driver.findElement(MobileBy.androidUIAutomator("your locator"));
//your actions are below
...

?

Maybe @Jonahss knows the solution. I think it is the server-side problem.

stonesong commented 8 years ago

@TikhomirovSergey It worked !! You were right, I was using WebElement instead of MobileElement and somehow now appium is okay with not resigning my apk ! That's great.

At least it work on my local Appium, then I am also trying with testObject and it does not look like having much effect on their appium server.

thanks a lot !

TikhomirovSergey commented 8 years ago

You also can

@AndroidFindBy(uiAutomator = etc.)
MobileElement e;
//your actions are below
...

That should work too. So. Can I close this ticket? You are free to close it on your own if you are sure that there is no problem anymore :)

stonesong commented 8 years ago

Sure that's how I did it actually, thanks again for you quick help !