-
-
Notifications
You must be signed in to change notification settings - Fork 305
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
chore: refactor session detail storage & retrieval #1942
Conversation
desiredCapabilities = addCustomCaps(desiredCapabilities); | ||
let sessionCaps = originalCaps ? getCapsObject(originalCaps) : {}; | ||
let host, port, username, accessKey, https, path, headers; | ||
sessionCaps = addCustomCaps(sessionCaps); | ||
|
||
switch (session.serverType) { | ||
case SERVER_TYPES.LOCAL: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe in the future it makes sense to modularize this switch, so we keep all vendor-specific capability transformers (as well as other vendor-specific stuff) in separate modules, for example, sauce.js
or perfecto.js
, which must implement one common base interface (defined by us)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fully agree, but that would also make this PR a lot bigger, so I would prefer to have a separate PR for that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ofc, not in the same PR
This is primarily a refactoring PR for the Session Information screen, but also adjusts the data format used when storing the initial session details, which is also used in the Session Information screen:
getSession
call into a separate method for consistencyisUsingMjpegMode
instead of implicitly convertingmjpegScreenshotUrl
to boolean