Skip to content

Commit 5b6d098

Browse files
committed
comments
1 parent fcb7f51 commit 5b6d098

File tree

19 files changed

+43
-40
lines changed

19 files changed

+43
-40
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
### Requirements
1111

12-
1. Java 8
12+
1. Java 8+
1313

1414
- If Java is not installed, follow these instructions:
1515
- For Windows, download latest java version from [here](https://java.com/en/download/) and run the installer executable

android/junit4-examples/pom.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,11 +56,12 @@
5656
<plugin>
5757
<groupId>org.apache.maven.plugins</groupId>
5858
<artifactId>maven-surefire-plugin</artifactId>
59-
<version>2.22.1</version>
59+
<version>2.22.2</version>
6060
</plugin>
6161
<plugin>
6262
<groupId>org.apache.maven.plugins</groupId>
6363
<artifactId>maven-compiler-plugin</artifactId>
64+
<version>3.8.1</version>
6465
<configuration>
6566
<source>1.8</source>
6667
<target>1.8</target>

android/junit4-examples/src/test/java/com/browserstack/run_local_test/BrowserStackJUnitTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
@RunWith(Parameterized.class)
3030
public class BrowserStackJUnitTest {
3131
public AndroidDriver<AndroidElement> driver;
32-
private Local l;
32+
private Local local;
3333

3434
private static JSONObject config;
3535

@@ -89,10 +89,10 @@ public void setUp() throws Exception {
8989
}
9090

9191
if (capabilities.getCapability("browserstack.local") != null && capabilities.getCapability("browserstack.local") == "true") {
92-
l = new Local();
92+
local = new Local();
9393
Map<String, String> options = new HashMap<String, String>();
9494
options.put("key", accessKey);
95-
l.start(options);
95+
local.start(options);
9696
}
9797

9898
driver = new AndroidDriver(new URL("http://" + username + ":" + accessKey + "@" + config.get("server") + "/wd/hub"), capabilities);
@@ -101,6 +101,6 @@ public void setUp() throws Exception {
101101
@After
102102
public void tearDown() throws Exception {
103103
driver.quit();
104-
if (l != null) l.stop();
104+
if (local != null) local.stop();
105105
}
106106
}

android/junit5-examples/pom.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@
6363
<plugin>
6464
<groupId>org.apache.maven.plugins</groupId>
6565
<artifactId>maven-surefire-plugin</artifactId>
66-
<version>2.22.1</version>
66+
<version>2.22.2</version>
6767
<configuration>
6868
<properties>
6969
<configurationParameters>
@@ -75,6 +75,7 @@
7575
<plugin>
7676
<groupId>org.apache.maven.plugins</groupId>
7777
<artifactId>maven-compiler-plugin</artifactId>
78+
<version>3.8.1</version>
7879
<configuration>
7980
<source>1.8</source>
8081
<target>1.8</target>

android/junit5-examples/src/test/java/com/browserstack/run_first_test/FirstTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@ void test(int taskId) throws IOException, InterruptedException {
2121
createConnection(taskId);
2222

2323
AndroidElement searchElement = (AndroidElement) new WebDriverWait(driver, 30).until(
24-
ExpectedConditions.elementToBeClickable(MobileBy.AccessibilityId("Search Wikipedia")));
24+
ExpectedConditions.elementToBeClickable(MobileBy.AccessibilityId("Search Wikipedia")));
2525
searchElement.click();
2626

2727
AndroidElement insertTextElement = (AndroidElement) new WebDriverWait(driver, 30).until(
28-
ExpectedConditions.elementToBeClickable(MobileBy.id("org.wikipedia.alpha:id/search_src_text")));
28+
ExpectedConditions.elementToBeClickable(MobileBy.id("org.wikipedia.alpha:id/search_src_text")));
2929
insertTextElement.sendKeys("BrowserStack");
3030

3131
Thread.sleep(5000);

android/junit5-examples/src/test/java/com/browserstack/run_local_test/BrowserStackJUnitTest.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
public class BrowserStackJUnitTest {
2626

2727
public AndroidDriver<AndroidElement> driver;
28-
private Local l;
28+
private Local local;
2929
public String username;
3030
public String accessKey;
3131
public DesiredCapabilities capabilities;
@@ -88,17 +88,17 @@ public void setup() throws Exception {
8888
}
8989

9090
if(capabilities.getCapability("browserstack.local") != null && capabilities.getCapability("browserstack.local") == "true"){
91-
l = new Local();
91+
local = new Local();
9292
Map<String, String> options = new HashMap<String, String>();
9393
options.put("key", accessKey);
94-
l.start(options);
94+
local.start(options);
9595
}
9696
}
9797

9898
@AfterEach
9999
public void tearDown() throws Exception {
100100
driver.quit();
101101

102-
if(l != null) l.stop();
102+
if(local != null) local.stop();
103103
}
104104
}

android/junit5-examples/src/test/java/com/browserstack/run_local_test/LocalTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,10 @@ void test(int taskId) throws IOException, InterruptedException {
2525
createConnection(taskId);
2626

2727
AndroidElement searchElement = (AndroidElement) new WebDriverWait(driver, 30).until(
28-
ExpectedConditions.elementToBeClickable(MobileBy.id("com.example.android.basicnetworking:id/test_action")));
28+
ExpectedConditions.elementToBeClickable(MobileBy.id("com.example.android.basicnetworking:id/test_action")));
2929
searchElement.click();
3030
AndroidElement insertTextElement = (AndroidElement) new WebDriverWait(driver, 30).until(
31-
ExpectedConditions.elementToBeClickable(MobileBy.className("android.widget.TextView")));
31+
ExpectedConditions.elementToBeClickable(MobileBy.className("android.widget.TextView")));
3232

3333
AndroidElement testElement = null;
3434
List<AndroidElement> allTextViewElements = driver.findElementsByClassName("android.widget.TextView");

android/junit5-examples/src/test/java/com/browserstack/run_parallel_test/ParallelTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ void test(int taskId) throws IOException, InterruptedException {
2121
createConnection(taskId);
2222

2323
AndroidElement searchElement = (AndroidElement) new WebDriverWait(driver, 30).until(
24-
ExpectedConditions.elementToBeClickable(MobileBy.AccessibilityId("Search Wikipedia")));
24+
ExpectedConditions.elementToBeClickable(MobileBy.AccessibilityId("Search Wikipedia")));
2525
searchElement.click();
2626
AndroidElement insertTextElement = (AndroidElement) new WebDriverWait(driver, 30).until(
27-
ExpectedConditions.elementToBeClickable(MobileBy.id("org.wikipedia.alpha:id/search_src_text")));
27+
ExpectedConditions.elementToBeClickable(MobileBy.id("org.wikipedia.alpha:id/search_src_text")));
2828
insertTextElement.sendKeys("BrowserStack");
2929
Thread.sleep(5000);
3030

android/junit5-examples/src/test/resources/com/browserstack/run_first_test/first.conf.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,3 @@
1515
"device": "Samsung Galaxy S7"
1616
}]
1717
}
18-

ios/junit4-examples/pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@
6161
<plugin>
6262
<groupId>org.apache.maven.plugins</groupId>
6363
<artifactId>maven-compiler-plugin</artifactId>
64+
<version>3.8.1</version>
6465
<configuration>
6566
<source>1.8</source>
6667
<target>1.8</target>

0 commit comments

Comments
 (0)