Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
scratch-www
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
scratch-www
Commits
8d5b1395
Commit
8d5b1395
authored
Sep 14, 2020
by
BryceLTaylor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pin chrome version for saucelabs to chromedriver version
parent
3286ec6d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
1 deletion
+10
-1
test/integration/selenium-helpers.js
test/integration/selenium-helpers.js
+10
-1
No files found.
test/integration/selenium-helpers.js
View file @
8d5b1395
...
...
@@ -8,6 +8,7 @@ const ci = process.env.CI || false;
const
buildID
=
process
.
env
.
TRAVIS_BUILD_NUMBER
;
const
{
SAUCE_USERNAME
,
SAUCE_ACCESS_KEY
}
=
process
.
env
;
const
{
By
,
Key
,
until
}
=
webdriver
;
const
pkg
=
require
(
'
../../package.json
'
);
const
DEFAULT_TIMEOUT_MILLISECONDS
=
20
*
1000
;
...
...
@@ -62,13 +63,21 @@ class SeleniumHelper {
return
driver
;
}
getChromeVersionNumber
()
{
let
chromedriverVersion
=
pkg
.
devDependencies
.
chromedriver
;
let
versionFinder
=
/
\d
+
\.\d
+/
;
let
versionArray
=
versionFinder
.
exec
(
chromedriverVersion
);
return
versionArray
[
0
];
}
getSauceDriver
(
username
,
accessKey
,
name
)
{
let
chromeVersion
=
this
.
getChromeVersionNumber
();
// Driver configs can be generated with the Sauce Platform Configurator
// https://wiki.saucelabs.com/display/DOCS/Platform+Configurator
let
driverConfig
=
{
browserName
:
'
chrome
'
,
platform
:
'
macOS 10.14
'
,
version
:
'
84.0
'
version
:
chromeVersion
};
var
driver
=
new
webdriver
.
Builder
()
.
withCapabilities
({
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment