Skip to content

Commit 3a2cd9e

Browse files
Merge pull request #33 from kamal-kaur04/modify-local-test-sdk
change sample local test
2 parents 302611e + 069f636 commit 3a2cd9e

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

browserstack.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,10 @@ parallelsPerPlatform: 1
5959
# Set browserStackLocal to true if your website under test is not accessible publicly over the internet
6060
# Learn more about how BrowserStack Local works here -> https://www.browserstack.com/docs/automate/selenium/local-testing-introduction
6161
browserstackLocal: true # <boolean> (Default false)
62-
# browserStackLocalOptions:
62+
#browserStackLocalOptions:
6363
# Options to be passed to BrowserStack local in-case of advanced configurations
64-
# - localIdentifier: # <string> (Default: null) Needed if you need to run multiple instances of local.
65-
# - forceLocal: true # <boolean> (Default: false) Set to true if you need to resolve all your traffic via BrowserStack Local tunnel.
64+
# localIdentifier: # <string> (Default: null) Needed if you need to run multiple instances of local.
65+
# forceLocal: true # <boolean> (Default: false) Set to true if you need to resolve all your traffic via BrowserStack Local tunnel.
6666
# Entire list of arguments available here -> https://www.browserstack.com/docs/automate/selenium/manage-incoming-connections
6767

6868
# ===================

src/test/java/com/browserstack/stepdefs/StackDemoSteps.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ public void product_should_be_added_to_cart() {
5151
Assert.assertEquals(homePage.getSelectedProductName(), homePage.getProductCartText());
5252
}
5353

54-
@Then("the page should contain '(.+)'$")
55-
public void page_should_contain(String expectedTitle) {
56-
Assert.assertTrue(driver.getPageSource().contains(expectedTitle));
54+
@Then("the page title should contain '(.+)'$")
55+
public void page_title_should_contain(String expectedTitle) {
56+
Assert.assertTrue(driver.getTitle().contains(expectedTitle));
5757
}
5858

5959
@After
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Feature: Verify Local test
22

3-
Scenario: Navigate to Local check page
4-
Given I am on the website 'http://bs-local.com:45691/check'
5-
Then the page should contain 'Up and running'
3+
Scenario: Navigate to Local App page
4+
Given I am on the website 'http://bs-local.com:45454/'
5+
Then the page title should contain 'BrowserStack Local'

0 commit comments

Comments
 (0)