Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ More can be found in the docs, but here's a quick list of features which this pr
- lockScreen()
- shake()
- complexFind()
- scrollTo()
- scrollToExact()
- Context Switching: .context(), .getContextHandles(), getContext())

Locators:
Expand All @@ -58,6 +60,9 @@ Locators:
- findElementsByAndroidUIAutomator()

##Changelog##
*1.2.0*
- complexFind() now returns MobileElement objects
- added scrollTo() and scrollToExact() methods for use with complexFind()
*1.1.0*
- AppiumDriver now implements Rotatable. rotate() and getOrientation() methods added
- when no appium server is running, the proper error is thrown, instead of a NullPointerException
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>io.appium</groupId>
<artifactId>java-client</artifactId>
<version>1.1.0</version>
<version>1.2.0</version>
<dependencies>
<dependency>
<groupId>com.google.collections</groupId>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package io.appium.java_client;

import org.apache.commons.codec.binary.Base64;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
Expand Down Expand Up @@ -89,12 +88,4 @@ public void ErrorTest() {
driver.findElementByAndroidUIAutomator(null);
}

@Test
public void pushFileTest() {
byte[] data = Base64.encodeBase64("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra".getBytes());
driver.pushFile("/data/local/tmp/remote.txt", data);
byte[] returnData = driver.pullFile("/data/local/tmp/remote.txt");
String returnDataDecoded = new String(Base64.decodeBase64(returnData));
assertEquals("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra", returnDataDecoded);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

package io.appium.java_client;

import org.apache.commons.codec.binary.Base64;
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
Expand Down Expand Up @@ -95,4 +96,13 @@ public void closeAppTest() throws InterruptedException {
driver.launchApp();
assertEquals(".ApiDemos", driver.currentActivity());
}

@Test
public void pushFileTest() {
byte[] data = Base64.encodeBase64("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra".getBytes());
driver.pushFile("/data/local/tmp/remote.txt", data);
byte[] returnData = driver.pullFile("/data/local/tmp/remote.txt");
String returnDataDecoded = new String(Base64.decodeBase64(returnData));
assertEquals("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra", returnDataDecoded);
}
}