appium

Appium server is shut down because no new commands came in

二次信任 提交于 2019-12-24 06:12:50
问题 I am using Appium for Android native app automation on windows machine. All my scenarios are doing good, but sometimes the App gets crashed and Appium stops saying "Didn't get a new command in 60 secs, shutting down". Note - if explicitly i press any key from keyboard it will get next command to execute while cucumber execution. I can see Appium is sending request to find the element, but no response has been received. I don't know why this is happening, but the same thing passes without any

Appium - Command line

梦想的初衷 提交于 2019-12-24 03:39:19
问题 Team, Can you please guide me or point me some tutorials to run Appium through command line? I see lot of issues with Appium.app on MAC. It would be great, if you can share your knowledge or materials for me to move forward to run a sample application with appium through command line. Please refer my settings in appium.app for your reference. Appium - Not able to launch the inspector Logs: info: [debug] Responding to client with success: {"status":0,"value":{"build":{"version":"1.2.2",

How to know App navigating to HomeActivity or LoginActivity - Appium

雨燕双飞 提交于 2019-12-24 01:43:22
问题 I am testing my mobile app using Appium . When app starting it directly navigation to HomeActivity sometimes(if user already logged in). If user not logged in then opening LoginActivity . So, how can I know which activity starting? so that I can execute logout code accordingly. This code not executing at all because app navigation to HomeActivity directly instead of LoginActivity . public void DemoTest() { AndroidElement editElement1 = driver.FindElementById("input_name"); editElement1.Clear(

How to know App navigating to HomeActivity or LoginActivity - Appium

拥有回忆 提交于 2019-12-24 01:43:08
问题 I am testing my mobile app using Appium . When app starting it directly navigation to HomeActivity sometimes(if user already logged in). If user not logged in then opening LoginActivity . So, how can I know which activity starting? so that I can execute logout code accordingly. This code not executing at all because app navigation to HomeActivity directly instead of LoginActivity . public void DemoTest() { AndroidElement editElement1 = driver.FindElementById("input_name"); editElement1.Clear(

Error while trying out touch actions using Appium

限于喜欢 提交于 2019-12-24 01:22:07
问题 Below is my code: package AppiumPackage; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; import org.openqa.selenium.WebElement; import org.openqa.selenium.interactions.touch.TouchActions; import org.openqa.selenium.remote.Augmenter; import org.openqa.selenium.remote.DesiredCapabilities; import org.openqa.selenium.remote.RemoteWebDriver; import org.openqa.selenium.support.ui.ExpectedConditions; import org.openqa.selenium.support.ui.WebDriverWait; import org.testng.Assert;

Python unittest appium

旧城冷巷雨未停 提交于 2019-12-24 01:17:57
import unittest from appium import webdriver from appium.common.exceptions import NoSuchContextException import desired_capabilities class ContextSwitchingTests(unittest.TestCase): def setUp(self): desired_caps = desired_capabilities.get_desired_capabilities('selendroid-test-app.apk') self.driver = webdriver.Remote('http://localhost:4723/wd/hub', desired_caps) def test_contexts_list(self): self._enter_webview() contexts = self.driver.contexts self.assertEqual(2, len(contexts)) def test_move_to_correct_context(self): self._enter_webview() self.assertEqual('WEBVIEW_io.selendroid.testapp', self

How to get app information like app version, device os version in ios using Appium?

筅森魡賤 提交于 2019-12-24 01:01:51
问题 I am testing the app using appium and integrating the test output in testrail. I need to add the device and app information in the testrail. In android i am able to get app and device information like device model, device version and app version using adb command like following: adb -s 012313gasda shell getprop ro.product.model adb -s 012313gasda shell getprop ro.build.version.release adb -s 012313gasda shell dumpsys package com.test.app |grep versionName How can i achieve the same

UiAutomator bug while inspecting WebView elements

﹥>﹥吖頭↗ 提交于 2019-12-24 00:53:44
问题 I have recently started automation testing in android and was using UiAutomator tool for inspecting UI elements. Surprisingly, I came across two different responses for Webview elements for the same screen and same device [Genymotion MotoX 4.4.4]. Attached are the screenshots for the same. We all know that appium has an issue with inspecting webview elements who do not carry "setWebContentsDebuggingEnabled" to true. Is this a bug in UiAutomator? 回答1: We all know that appium has an issue with

python脚本中appium的自启动自关闭

余生颓废 提交于 2019-12-24 00:17:56
前提:已安装appium命令行版本 将appium的启动及其关闭直接写在脚本中,运行起来会方便很多 创建startAppiumServer.bat 和 stopAppiumServer.bat文件,然后文件存放在运行的包下面 注意点:调用startAppiumServer.bat 和stopAppiumServer.bat时,可用“start /b”开头或“start”开头,个人更喜欢用“start /b”开头 用“start /b”开头,appium的日志会输出至控制台,用“start”开头的话,会输出至窗口,导致每次运行脚本,都会新增两个窗口(开始和结束) startAppiumServer.bat @echo off title startAppiumServer cmd /c "appium -a 127.0.0.1 -p 4723" stopAppiumServer.bat @echo off title stopAppiumServer tasklist /V|find "startAppiumServer">nul if %errorlevel%==0 ( ::关闭appium服务 taskkill /F /IM node.exe taskkill /F /FI "WINDOWTITLE eq startAppiumServer" ) taskkill /F /FI

Appium (v1.4.16.1), Switch to WebView fails when i try a second time

*爱你&永不变心* 提交于 2019-12-24 00:16:33
问题 Appium (v1.4.16.1), Switch to WebView fails when I try to switch to webview second time. Is there something I should be considering? Please refer to the below use case using Appium on Android- Launch Android Device > Perform some actions Switch context = WebView_1 > Perform some actions Switch context = Native_App Switch context = WebView_1 > Perform some actions In Step#2 and Step#4, it is the same WebView_1, but the content is different. Say: step#2 opened html-1 and step#4 opened html-2.