appium

Running Android emulator Hyper-V based on a Azure VM Windows Server 2016

柔情痞子 提交于 2019-12-24 19:01:07
问题 Our goal is to run UI tests with Appium on our CI build. But it seems that running the Android emulator (Hyper-V based) within virtual build machine (Windows Server 2016) on Azure might not be supported. So my question is, does Hyper-V based nested virtualization is supported from a Windows Server 2016 virtual machine on Azure ? note: using a CPU Android emulation is not an option 回答1: Yes, it is possible, you need to be on Dv3 or Ev3 SKU. https://docs.microsoft.com/en-us/azure/virtual

how to confirm a NumberPicker after sending data with Appium

…衆ロ難τιáo~ 提交于 2019-12-24 16:22:13
问题 I write test automation for Android Native app. And I want to enter/send value to a NumberPicker, my code is below: WebElement heightValue = appiumDriver.findElement(By.className("android.widget.NumberPicker")); heightValue.sendKeys("180"); appiumDriver.findElement(By.id("com.kmp.connect.coach:id/buttonDefaultPositive")).click(); Problem is, I have to click confirm on native keyboard and then click OK button of my app, then value is set. But I can not interfere with native keyboard. I try

Can a build be marked as failed from an Xcode bot trigger script?

橙三吉。 提交于 2019-12-24 15:26:36
问题 I'm using a post-build trigger script in an Xcode bot to run some tests through Appium. I've gotten it to run, but I can't find any way to mark the build as failed if the tests fail. Is this possible, or should I just email the results for now and wait to move to a different CI system? Documentation for these bot trigger scripts is sketchy at best. 来源: https://stackoverflow.com/questions/28614615/can-a-build-be-marked-as-failed-from-an-xcode-bot-trigger-script

java.lang.NoSuchFieldError: INSTANCE exception is thrown by appium driver varriable

六眼飞鱼酱① 提交于 2019-12-24 14:23:43
问题 I am trying to write this java class that opens an apk file in an android device and presses some buttons through appium,using the code below: package new_appium_test; import io.appium.java_client.android.AndroidDriver; import io.appium.java_client.remote.MobileCapabilityType; import java.io.File; import java.net.MalformedURLException; import java.net.URL; import java.util.concurrent.TimeUnit; import org.junit.After; import org.junit.Before; import org.junit.Test; import org.openqa.selenium

How to enter numeric values using mobile keypad in android app in python script using Appium

不想你离开。 提交于 2019-12-24 11:37:45
问题 I am writing a python script to automate android application. I want to enter values in text board using mobile keypad . I was able to enter the value in text field using send_keys , but in some cases I have to enter values using android keypad i.e digits(1,2,3,4,5,6,7,8,9,0) etc. Can anyone tell me how to enter these value using keypad? 回答1: try this emailSign = self.driver.find_element_by_class_name("UIATextField") passSign = self.driver.find_element_by_class_name("UIASecureTextField")

How to accept this alert in appium?

北慕城南 提交于 2019-12-24 09:49:59
问题 Appium v1.6.4-beta Xcode 8.2 macOs Sierra 10.12 I want to automate to save photo in my device. But in first time I have to give permission. I have used "accept alert", but cannot accept the alert for allow to access the photo library. It shows the test passed in green , when I execute the test, but this popup still appear in view and photo is not saved. This is my script //Check Save driver.findElement(By.id("Save")).click(); driver.switchTo().alert().accept(); Capabilities also used ,

How to have multiple Cucumber step definitions in the same project for testing product variants

二次信任 提交于 2019-12-24 08:25:39
问题 I'm working on an automation project for a mobile app in ios and android. I'm using Java-Appium-Cucumber framework for writing tests. Below shows my project structure src android features step_definitions ios features step_definitions I need a step "User logins to the app" for both android and ios. But the implementation in android and ios are different. So I wrote two step definitions in android > step_definitions and in ios > step_definitions. But this results in duplicate step definition

java.lang.VerifyError: Cannot inherit from final class

依然范特西╮ 提交于 2019-12-24 08:12:34
问题 I'm having an issue with this appium driver i'm running with java. I'm not exactly sure what I did that caused this error. I was reorganizing my jar files an re configured them. However that shouldn't be what was causing it. I also tried starting appium programatically. but that deem unsuccessful. So I deleted that code and started getting this error. It stops right on this code "driver = new AndroidDriver(appiumURL, capabilities);" after initiating driver capabilities and URL. It use to work

Appium TestNG - How to identify an element in other languages

时光总嘲笑我的痴心妄想 提交于 2019-12-24 07:39:21
问题 i´m using Appium/TestNG in real devices to automate an application, but some elements have the [@text='string'] with other languages. what´s the best solution to use the same code on other languages instead of creating one code for each language ? 回答1: Best practice is to never use XPath locators like //*[@text='string'] For Android apps use resource-id or uiautomator locator strategies For iOS apps accessibility-id or ios class chain locator strategies It will help to keep your tests stable

How to make sure the appium node is connected to only one phone?

泄露秘密 提交于 2019-12-24 07:37:25
问题 I run (all on one machine) multiple appium servers connected as nodes to a selenium-grid hub and I have multiple phones connected to my adb on port 5555 (in my case via WiFi). The issue I have with this is that two of the three phones have capabilities that are matching (Android 7.1.1, Chrome browser). So when I fire up a test for the nexus 9, if occupies the grid node for nexus 6. Or even the other way around, I ask to run the test on the nexus 6, this one get occupied, but the test runs on