Skip to content

Commit dbfa459

Browse files
committed
reorganize tests
1 parent ac43e99 commit dbfa459

File tree

2 files changed

+10
-9
lines changed

2 files changed

+10
-9
lines changed

src/test/java/io/appium/java_client/AndroidUIAutomatorTest.java

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
package io.appium.java_client;
22

3-
import org.apache.commons.codec.binary.Base64;
43
import org.junit.After;
54
import org.junit.Before;
65
import org.junit.Test;
@@ -89,12 +88,4 @@ public void ErrorTest() {
8988
driver.findElementByAndroidUIAutomator(null);
9089
}
9190

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

src/test/java/io/appium/java_client/MobileDriverAndroidTest.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
package io.appium.java_client;
1919

20+
import org.apache.commons.codec.binary.Base64;
2021
import org.junit.After;
2122
import org.junit.Before;
2223
import org.junit.Test;
@@ -95,4 +96,13 @@ public void closeAppTest() throws InterruptedException {
9596
driver.launchApp();
9697
assertEquals(".ApiDemos", driver.currentActivity());
9798
}
99+
100+
@Test
101+
public void pushFileTest() {
102+
byte[] data = Base64.encodeBase64("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra".getBytes());
103+
driver.pushFile("/data/local/tmp/remote.txt", data);
104+
byte[] returnData = driver.pullFile("/data/local/tmp/remote.txt");
105+
String returnDataDecoded = new String(Base64.decodeBase64(returnData));
106+
assertEquals("The eventual code is no more than the deposit of your understanding. ~E. W. Dijkstra", returnDataDecoded);
107+
}
98108
}

0 commit comments

Comments
 (0)