简体   繁体   English

AWS Appium ios测试始终失败

[英]AWS appium ios test always fail

I am implementing aws automation testing using appium junit . 我正在使用appium junit实施AWS自动化测试。

i am trying to run my testing script on aws device farm , my test script is working fine on simulator but its failing on aws devices. 我试图在aws设备场上运行我的测试脚本,我的测试脚本在模拟器上工作正常,但在aws设备上失败。 error does not describes the problem correctly. 错误不能正确描述问题。

Whenever i run my script on aws devices it gives me following error. 每当我在AWS设备上运行脚本时,都会出现以下错误。 when i see the video, application was successfully launched and then nothing happens on the screen. 当我看到视频时,应用程序已成功启动,然后屏幕上没有任何反应。 i can see first popup that asks to allow push notifications and then after popover gets dismiss nothing happens. 我可以看到第一个要求允许推送通知的弹出窗口,然后在关闭弹出窗口后什么也没有发生。

  failed: An error occurred while executing user supplied JavaScript. 
(WARNING: The server did not provide any stacktrace information) Command
 duration or timeout: 1.48 seconds Build info: version: '2.53.0', revision:
 '35ae25b1534ae328c771e0856c93e187490ca824', time: '2016-03-15 10:43:46' 
System info: host: 'ip-172-31-13-65', ip: '172.31.13.65', os.name: 'Linux',
 os.arch: 'amd64', os.version: '3.13.0-53-generic', java.version: 
'1.8.0_65' Driver info: io.appium.java_client.ios.IOSDriver Capabilities 
[{networkConnectionEnabled=false, desired={}, warnings={}, 
webStorageEnabled=false, locationContextEnabled=false, browserName=iOS, 
takesScreenshot=true, javascriptEnabled=true, databaseEnabled=false, 
platform=MAC}] Session ID: ca42e475-f253-40ed-a143-fef52146f655

and here is my java appium test script 这是我的Java appium测试脚本

DesiredCapabilities capabilities = new DesiredCapabilities();
        capabilities.setCapability(MobileCapabilityType.PLATFORM_NAME, MobilePlatform.IOS);
        capabilities.setCapability(MobileCapabilityType.PLATFORM_VERSION, "9.1");
        capabilities.setCapability(MobileCapabilityType.DEVICE_NAME, "iPhone 5s");
        capabilities.setCapability(CapabilityType.BROWSER_NAME, MobilePlatform.IOS);
        capabilities.setCapability("autoAcceptAlerts", true);
        capabilities.setCapability("showIOSLog", true);
        capabilities.setCapability(CapabilityType.SUPPORTS_NETWORK_CONNECTION, true);



        String path = "/Users/home/Desktop/";
        File app;
        app = new File(path,"projectapp.ipa");
        capabilities.setCapability(MobileCapabilityType.APP, app.getAbsolutePath());

        capabilities.setCapability(MobileCapabilityType.FULL_RESET, false);
        capabilities.setCapability(MobileCapabilityType.NO_RESET, true);

        URL url =new URL("http://127.0.0.1:4723/wd/hub");
        driver = new IOSDriver<WebElement>(url, capabilities);

i posted a question on aws forums no one awsering. 我在aws论坛上发布了一个没人问的问题。

https://forums.aws.amazon.com/thread.jspa?threadID=247887 https://forums.aws.amazon.com/thread.jspa?threadID=247887

Don't set any DesiredCapabilities except for the URL. 除URL外,不要设置任何DesiredCapabilities Resources to assist further are: 进一步协助的资源是:

If you need specific assistance, please open a support case with AWS or post your issue on the AWS Device Farm forum and we can assist further. 如果您需要特定的帮助,请打开AWS的支持案例或将您的问题发布到AWS Device Farm论坛上 ,我们将为您提供进一步的帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM