zero tests to run and com.google.android.apps.chrome.Main does not exist

0

Hi,

I run tests on Web app mobile but I have this error : Activity class {com.android.chrome/com.google.android.apps.chrome.Main} does not exist. And 0 tests to run.

I'm using multiple combinaisons of params of Capabilities but no success. I'm using custom environment offers by default (the standard environment not working also) I'm using a simple test :

    DesiredCapabilities capabilities = new DesiredCapabilities();
    capabilities.setCapability(AUTOMATION_NAME, "UIAutomator2");
    driver = new AndroidDriver<>(new URL("http://127.0.0.1:4723/wd/hub"), capabilities);
    driver.manage().timeouts().implicitlyWait(60, SECONDS);
    driver.get("https://mywebsite.com");

Have you a simple example for testing Appium Web Java JUnit with DesiredCapabilities to include and the custom file yaml that work fine ?

Thank you

已提问 1 年前310 查看次数
1 回答
0

Hello,

This is Tom from AWS Support.

I see that we would like to use Appium Junit with Appium Desired Capabilities.

Device Farm supports the use of Desired Capabilities through custom test environments setup. Please note that, according to Device Farm documentation shown here [1], Appium capabilities must be a shell-escaped, quoted JSON structure.

For more information about setting up custom test environment and sample YAML specifications, please refer to this page [2]. Please note that the example shown here is for TestNG suite, but the syntax shall be similar to JUnit test.

This guide [3] shows step-by-step guide in how to create and build Appium test for Device Farm. For sample code solutions, here are the GitHub repository for both Android [4] and iOS [5].

I hope the above resources are helpful for developing Appium test. Have a nice day.

Links and References

[1] https://docs.aws.amazon.com/devicefarm/latest/developerguide/custom-test-environments-extending.html#w12aac28c19b7

[2] https://docs.aws.amazon.com/devicefarm/latest/developerguide/custom-test-environments.html#custom-test-environment-example

[3] https://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-appium.html

[4] https://github.com/aws-samples/aws-device-farm-sample-app-for-android

[5] https://github.com/aws-samples/aws-device-farm-sample-app-for-ios

AWS
支持工程师
Tom_T
已回答 1 年前

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则