You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When providing a a specific version of chromedriver in the driver object of installArgs and args, selenium-standalone should attempt to find an exact match, and if no exact match is found then it should look for the latest major version with the existing logic.
## If you're suggesting a change/improvement, tell us how it should work.
The getLastChromedriverVersionFromMajor function in compute-download-urls.js does a prefix match based on the chromedriver version provided in the driver object. We can do an exact match search first and if no match is found then the current logic can be executed.
## Proposed solution:
async function getLastChromedriverVersionFromMajor(version) {
const response = await got({
method: 'get',
url: 'https://googlechromelabs.github.io/chrome-for-testing/known-good-versions-with-downloads.json',
responseType: 'json',
headers: {
'Content-Type': 'application/json',
},
});
const exactMatch = response.body.versions.find(
(f) => f.version === version && 'chromedriver' in f.downloads
);
// If exact match is found, return it
if (exactMatch) {
return exactMatch;
}
const versionsWithMajor = response.body.versions.filter(
(f) =>
validateMajorVersionPrefix(f.version) === validateMajorVersionPrefix(version) && 'chromedriver' in f.downloads
);
versionsWithMajor
.sort((version1, version2) => {
return version1.version.localeCompare(version2.version, undefined, { numeric: true, sensitivity: 'base' });
})
.reverse();
return versionsWithMajor.length ? versionsWithMajor[0] : null;
}
## Current Behavior
Current behavior does a major version match on the provided chromedriver version in the driver object against the lsit of chromedrivers matching the major version. Then it sorts the matched result and returns the latest major version.
## Steps to Reproduce
Run WebdriverIO test with selenium-standalone service with an old chromedriver version to support older chrome browser installation.
## Your Environment
selenium-standalone: 9.5.0
webdriverio: 7.36.0
## Is there another tool calling selenium-standalone on your behalf:
webdriverio v7
## System/platform:
Mac/Windows/Linux
## Other details that might be important:
This request is to support older browser installtions where testers are not able to upgrade the chrome version due to organizational restrictions. Updating to WebdriverIO V8 is not an immediate option due to organizational limitations and is in the roadmap.
The text was updated successfully, but these errors were encountered:
## Expected Behavior
When providing a a specific version of chromedriver in the driver object of installArgs and args, selenium-standalone should attempt to find an exact match, and if no exact match is found then it should look for the latest major version with the existing logic.
## If you're suggesting a change/improvement, tell us how it should work.
The getLastChromedriverVersionFromMajor function in compute-download-urls.js does a prefix match based on the chromedriver version provided in the driver object. We can do an exact match search first and if no match is found then the current logic can be executed.
## Proposed solution:
## Current Behavior
Current behavior does a major version match on the provided chromedriver version in the driver object against the lsit of chromedrivers matching the major version. Then it sorts the matched result and returns the latest major version.
## Steps to Reproduce
Run WebdriverIO test with selenium-standalone service with an old chromedriver version to support older chrome browser installation.
## Your Environment
selenium-standalone: 9.5.0
webdriverio: 7.36.0
## Is there another tool calling
selenium-standalone
on your behalf:webdriverio v7
## System/platform:
Mac/Windows/Linux
## Other details that might be important:
This request is to support older browser installtions where testers are not able to upgrade the chrome version due to organizational restrictions. Updating to WebdriverIO V8 is not an immediate option due to organizational limitations and is in the roadmap.
The text was updated successfully, but these errors were encountered: