Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement LambdaTest remote driver support. #5536

Merged
merged 1 commit into from
Jul 25, 2024
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
2 changes: 1 addition & 1 deletion jdi-bdd-tests/src/test/resources/test.properties
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ json.page.objects=/json/page/objects
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
screenshot.strategy=on failure
html.code.strategy=on failure
Expand Down
2 changes: 1 addition & 1 deletion jdi-eyes-demo/src/test/resources/test.properties
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ domain=${domain}
driver.getLatest=true
smart.locator=#%s
log.level=STEP
#remote.type=sauce | browserstack | selenium_localhost
#remote.type=sauce | browserstack | lambdatest | selenium_localhost
#search.element.strategy=strict | soft | visible, multiple | any, single
#assert.type=soft | strict

Expand Down
2 changes: 1 addition & 1 deletion jdi-light-angular-tests/src/test/resources/test.properties
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ log.level=INFO
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
screenshot.strategy=on failure|on assert
#headless=true | false
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ domain=${domain}
driver.getLatest=true
smart.locator=#%s
log.level=STEP
#remote.type=sauce | browserstack | selenium_localhost
#remote.type=sauce | browserstack | lambdatest | selenium_localhost
#search.element.strategy=strict | soft | visible, multiple | any, single
#assert.type=soft | strict

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ log.info.details=element
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#headless=true | false
screenshot.strategy=on failure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,15 @@ public class RemoteDriverInfo {
public static String browserstack() {
return browserstack(getenv("USERNAME"), getenv("ACCESS_KEY"));
}
public static String lambdatest() {
return lambdatest(getenv("USERNAME"), getenv("ACCESS_KEY"));
}
public static String browserstack(String userName, String accessKey) {
return getRemoteURL(format("https://%s:%[email protected]/", userName, accessKey));
}
public static String lambdatest(String userName, String accessKey) {
return getRemoteURL(format("https://%s:%[email protected]/", userName, accessKey));
}
public static String appium() {return getRemoteURL("http://0.0.0.0:4723/");}
public static String getRemoteURL() {
return getRemoteURL(DRIVER.remoteUrl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,7 @@ private static String getRemoteUrl(String prop) {
DRIVER.capabilities.common = sauceCapabilities();
return SAUCE_LABS;
case "browserstack": return browserstack();
case "lambdatest": return lambdatest();
case "selenoid": return SELENOID_LOCAL;
default: return SELENIUM_LOCAL_HOST;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
{
"name": "remote.type",
"type": "java.lang.String",
"description": "Specify remote run type: sauce labs, browserstack, selenium grid",
"description": "Specify remote run type: sauce labs, browserstack, lamdatest, selenium grid",
"defaultValue": "selenium localhost"
},
{
Expand Down Expand Up @@ -608,6 +608,10 @@
"value": "browserstack",
"description": "Use BrowserStack capabilities to run tests remotely"
},
{
"value": "lambdatest",
"description": "Use LambdaTest capabilities to run tests remotely"
},
{
"value": "selenium localhost",
"description": "Use Selenium to run tests remotely, driver.remote.url should be specified."
Expand Down
2 changes: 1 addition & 1 deletion jdi-light-html-tests/src/test/resources/test.properties
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ log.info.details=element
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#headless=true | false
screenshot.strategy=on failure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ log.level=INFO
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#screenshot.strategy=on fail | on | off
#headless=true | false
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,15 @@ public class RemoteDriverInfo {
public static String browserstack() {
return browserstack(getenv("USERNAME"), getenv("ACCESS_KEY"));
}
public static String lambdatest() {
return lambdatest(getenv("USERNAME"), getenv("ACCESS_KEY"));
}
public static String browserstack(String userName, String accessKey) {
return getRemoteURL(format("https://%s:%[email protected]/", userName, accessKey));
}
public static String lambdatest(String userName, String accessKey) {
return getRemoteURL(format("https://%s:%[email protected]/", userName, accessKey));
}
public static String appium() {return getRemoteURL("http://0.0.0.0:4723/");}
public static String getRemoteURL() {
return getRemoteURL(DRIVER.remoteUrl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,7 @@ private static String getRemoteUrl(String prop) {
DRIVER.capabilities.common = sauceCapabilities();
return SAUCE_LABS;
case "browserstack": return browserstack();
case "lambdatest": return lambdatest();
case "selenoid": return SELENOID_LOCAL;
default: return SELENIUM_LOCAL_HOST;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@
{
"name": "remote.type",
"type": "java.lang.String",
"description": "Specify remote run type: sauce labs, browserstack, selenium grid",
"description": "Specify remote run type: sauce labs, browserstack, lambdatest, selenium grid",
"defaultValue": "selenium localhost"
},
{
Expand Down Expand Up @@ -604,6 +604,10 @@
"value": "browserstack",
"description": "Use BrowserStack capabilities to run tests remotely"
},
{
"value": "lambdatest",
"description": "Use LambdaTest capabilities to run tests remotely"
},
{
"value": "selenium localhost",
"description": "Use Selenium to run tests remotely, driver.remote.url should be specified."
Expand Down
2 changes: 1 addition & 1 deletion jdi-light-vuetify-tests/src/test/resources/test.properties
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ log.level=INFO
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#screenshot.strategy=on fail | on | off
headless=true
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ json.page.objects=/json/page/objects
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#screenshot.strategy=on failure | on | off
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ log.info.details=element
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#headless=true | false
screenshot.strategy=on failure
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ domain=${domain}
driver.getLatest=true
smart.locator=#%s
log.level=INFO
#remote.type=sauce | browserstack | selenium_localhost
#remote.type=sauce | browserstack | lambdatest | selenium_localhost
#search.element.strategy=strict | soft | visible, multiple | any, single
#assert.type=soft | strict

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ domain=${domain}
driver.getLatest=true
smart.locator=#%s
log.level=INFO
#remote.type=sauce | browserstack | selenium_localhost
#remote.type=sauce | browserstack | lambdatest | selenium_localhost
#search.element.strategy=strict | soft | visible, multiple | any, single
#assert.type=soft | strict

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ log.info.details=element
#log.message.format=short | full
#demo.mode=false | true
#demo.delay=2
#remote.type=sauce | browserstack
#remote.type=sauce | browserstack | lambdatest
#driver.remote.url=http://localhost:4444/wd/hub
#headless=true | false
screenshot.strategy=on failure
Expand Down
Loading