Skip to content

Instantly share code, notes, and snippets.

View gist:c9c8d8bdb007d57f0ffe895d92bac38e
Running '/Users/administrator/Desktop/android_sdk/platform-tools/adb -P 5037 -s ZY223Q76Q6 shell am start -W -a android.intent.action.VIEW -d https\://www.viki.com/home com.viki.android'
[W3C] Encountered internal error running command: Error: Error attempting to start URI. Original error: Error: Starting: Intent { act=android.intent.action.VIEW dat=https://www.viki.com/... pkg=com.viki.android }
[W3C] Error: Activity not started, unable to resolve Intent { act=android.intent.action.VIEW dat=https://www.viki.com/... flg=0x10000000 pkg=com.viki.android }
[W3C] at ADB.callee$0$0$ (/usr/local/lib/node_modules/appium/node_modules/appium-adb/build/lib/tools/apk-utils.js:129:15)
[W3C] at tryCatch (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:67:40)
[W3C] at GeneratorFunctionPrototype.invoke [as _invoke] (/usr/local/lib/node_modules/appium/node_modules/babel-runtime/regenerator/runtime.js:315:22)
[W3C] at GeneratorFunctionPrototype.prototype.(anonymous function
View TestSuite.xml
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="TestSuite" parallel="tests" thread-count="4">
<test name="Test on 1 device">
<parameter name="deviceName" value="emulator-5554" />
<parameter name="udid" value="emulator-5554" />
<parameter name="os" value="6.0" />
<parameter name="port" value="64738" />
<parameter name="platform" value="Android" />
View LocalizationTestSuite.java
package test;
import java.io.IOException;
import java.net.MalformedURLException;
import logger.Log;
import infra.DriverClass;
import io.appium.java_client.AppiumDriver;
import io.appium.java_client.MobileElement;
import org.openqa.selenium.remote.DesiredCapabilities;
import org.testng.annotations.AfterSuite;
View AllPageHandler.java
package ScreenHandler;
import PageObjectBase.AppSettingPage;
import PageObjectBase.LoginPage;
import pageObjects.LoginPage_ES;
import pageObjects.LoginPage_Eng;
import pageObjects.LoginPage_FR;
import pageObjects.LoginPage_PT;
import pageObjects.SettingPage_ES;
import pageObjects.SettingPage_Eng;
View LoginPage.java
package PageObjectBase;
import org.openqa.selenium.support.PageFactory;
import org.openqa.selenium.support.ui.ExpectedConditions;
import org.openqa.selenium.support.ui.WebDriverWait;
import io.appium.java_client.AppiumDriver;
import io.appium.java_client.MobileElement;
import io.appium.java_client.pagefactory.AppiumFieldDecorator;
import pageInterface.AppLoginInterface;
View LoginPage_FR.java
package pageObjects;
import pageInterface.AppLoginInterface;
import io.appium.java_client.MobileElement;
import io.appium.java_client.pagefactory.AndroidFindBy;
public class LoginPage_FR implements AppLoginInterface {
@AndroidFindBy(uiAutomator = "new UiSelector().text(\"Adresse e-mail ou identifiant\")")
View LoginPage_Eng.java
package pageObjects;
import io.appium.java_client.MobileElement;
import io.appium.java_client.pagefactory.AndroidFindBy;
import pageInterface.AppLoginInterface;
public class LoginPage_Eng implements AppLoginInterface {
View AppLoginInterface.java
package pageInterface;
import io.appium.java_client.MobileElement;
public interface AppLoginInterface {
public MobileElement getUserName();
public MobileElement getNextButton();
You can’t perform that action at this time.