diff options
author | Kevin Jin <kjin@google.com> | 2015-02-20 09:35:39 -0800 |
---|---|---|
committer | Kevin Jin <kjin@google.com> | 2015-02-20 14:37:53 -0800 |
commit | 4b31201b5a2dbf8036da5a8d089a68a39cc1dc44 (patch) | |
tree | 0a4a6d976ca45f3b87433927d57d50cb3cd51b41 /manualtest | |
parent | 85a1731f32032690e528a6ca1084aa148200569b (diff) | |
download | droiddriver-4b31201b5a2dbf8036da5a8d089a68a39cc1dc44.tar.gz |
rename package 'com.google.android' to 'io.appium'
Change-Id: I2c7c96cd6a6971806e2ea7b06cd6c2c6666e4340
Diffstat (limited to 'manualtest')
-rw-r--r-- | manualtest/AndroidManifest.xml | 6 | ||||
-rw-r--r-- | manualtest/build.gradle | 4 | ||||
-rw-r--r-- | manualtest/src/io/appium/droiddriver/manualtest/ManualTest.java (renamed from manualtest/src/com/google/android/droiddriver/manualtest/ManualTest.java) | 24 |
3 files changed, 16 insertions, 18 deletions
diff --git a/manualtest/AndroidManifest.xml b/manualtest/AndroidManifest.xml index e628e32..7e07f25 100644 --- a/manualtest/AndroidManifest.xml +++ b/manualtest/AndroidManifest.xml @@ -1,11 +1,11 @@ <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" - package="com.google.android.droiddriver.manualtest"> + package="io.appium.droiddriver.manualtest"> <instrumentation - android:name="com.google.android.droiddriver.runner.TestRunner" - android:targetPackage="com.google.android.droiddriver.manualtest" /> + android:name="io.appium.droiddriver.runner.TestRunner" + android:targetPackage="io.appium.droiddriver.manualtest" /> <!-- Needed for Android.mk --> <uses-sdk diff --git a/manualtest/build.gradle b/manualtest/build.gradle index 5cbfce3..91fb5eb 100644 --- a/manualtest/build.gradle +++ b/manualtest/build.gradle @@ -19,8 +19,8 @@ android { minSdkVersion 12 targetSdkVersion 21 // Force remove the suffix '.test' - testApplicationId 'com.google.android.droiddriver.manualtest' - testInstrumentationRunner 'com.google.android.droiddriver.runner.TestRunner' + testApplicationId 'io.appium.droiddriver.manualtest' + testInstrumentationRunner 'io.appium.droiddriver.runner.TestRunner' } sourceSets { diff --git a/manualtest/src/com/google/android/droiddriver/manualtest/ManualTest.java b/manualtest/src/io/appium/droiddriver/manualtest/ManualTest.java index c1f3946..6e95272 100644 --- a/manualtest/src/com/google/android/droiddriver/manualtest/ManualTest.java +++ b/manualtest/src/io/appium/droiddriver/manualtest/ManualTest.java @@ -1,24 +1,22 @@ -package com.google.android.droiddriver.manualtest; +package io.appium.droiddriver.manualtest; import android.app.Activity; -import com.google.android.droiddriver.actions.TextAction; -import com.google.android.droiddriver.finders.By; -import com.google.android.droiddriver.finders.Finder; -import com.google.android.droiddriver.helpers.BaseDroidDriverTest; -import com.google.android.droiddriver.helpers.DroidDrivers; +import io.appium.droiddriver.finders.By; +import io.appium.droiddriver.finders.Finder; +import io.appium.droiddriver.helpers.BaseDroidDriverTest; /** * This is for manually testing DroidDriver. It is not meant for continuous * testing. Instead it is used for debugging failures. It assumes the device is * in a condition that is ready to reproduce a failure. For example, * {@link #testSetTextForPassword} assumes the password_edit field is displayed - * on screen and has input focus. + * on screen. * <p> * Run it as (optionally with -e debug true) * * <pre> - * adb shell am instrument -w com.google.android.droiddriver.manualtest/com.google.android.droiddriver.runner.TestRunner + * adb shell am instrument -w io.appium.droiddriver.manualtest/io.appium.droiddriver.runner.TestRunner * </pre> */ public class ManualTest extends BaseDroidDriverTest<Activity> { @@ -28,13 +26,13 @@ public class ManualTest extends BaseDroidDriverTest<Activity> { public void testSetTextForPassword() { Finder password_edit = By.resourceId("com.google.android.gsf.login:id/password_edit"); - driver.on(password_edit).perform( - new TextAction("A fake password that is not empty and needs to be cleared by setText")); - String password = "1"; - driver.on(password_edit).setText(password); + String oldPassword = "A fake password that is not empty and needs to be cleared by setText"; + String newPassword = "1"; + driver.on(password_edit).setText(oldPassword); + driver.on(password_edit).setText(newPassword); // This won't work because password_edit does not reveal text to // Accessibility service. But you can see the length changed on screen. - // assertEquals(password, driver.on(password_edit).getText()); + // assertEquals(newPassword, driver.on(password_edit).getText()); assertEquals(null, driver.on(password_edit).getText()); } } |